SQL Database Connector Live vs Dev

Hi, there is a response here saying that to deploy an application to live that uses the bubble sql connector plug in then all workflows need to have two queries, one that runs on a condition that the user is in dev and one when user is on live. Is there another method that avoids this duplication?

We have tried setting up two connections and just changing the connection on live, but the live version doesnt seem to use the live connection string, presumably as live is read only?

Any ideas welcome. Thanks.

Hi,

I create a boolean type field in my SQL database, usually called “test”.

Inside Bubble I use the “isn’t live” operator to know if the record comes from live or a development version.

Also, sometimes I add another text field in SQL where I store the name of the version/branch to know which one it comes from specifically in case it is not live.

Now it’s just a matter of filtering the data to only receive or see the data you need.

PS. I also create a querie to remove those records that are test records easily, using the same filter mentioned above.

1 Like