Changing Bundle contents

sridarvenkatesa
Level 1
Changing Bundle contents

Hi Team, We have a case where we need to update all our recipe codes(SQL/Python) to modify the existing database name and schema name to a new one. Unfortunately, the existing code is a pain as we have no variables implemented for database name and schema name instead its hardcoded. Rather than modifying each and every code manually, Is there a way to replace the database name globally?

I was thinking to export the Bundle and modify the database or schema name text to new one but i assume this may impact or break the code. Any thoughts welcome? Meanwhile, we will do a POC to see if we can alter Bundle contents (Not sure if its possible as we havent checked the contents of bundle yet)

Regards,

Sridar Venkatesan

0 Kudos
1 Reply
Marlan

Hi @sridarvenkatesa,

Your thought is to export the project to a zip file, unzip it, make the changes (using a search and replace tool presumably), and then zip and reimport it?

I don't know for sure but I'd think that could work. 

You could also use the Python API (dataikuapi) to make the changes in place. Let me know if this is of interest as I have some code you could modify to do this. We are using this approach to partially convert SQL recipes in our projects from Netezza SQL to Snowflake SQL. 

Marlan

0 Kudos