How to update existing data using Bubble Export?

I’m really excited about the way can be used to accomplish a much-needed workaround for users who want to remotely connect to a MySQL database that only allows access to a whitelist of IP addresses:

My goal
Since applications are hosted on a dynamic IP address, the company is not able to provide a reliable IP address for users to whitelist in the MySQL database host security settings (as many hosts require).

But since does have a reliable set of IP addresses, I can whitelist them in MySQL and then use to remotely connect to my MySQL database, import, and then export it to my application.

My issue
But I’m encountering one big problem…I can’t figure out how to update existing data records in Bubble using Parabola. I have only successfully posted new records (using POST). When I try uploading the same thing twice and want it to simply update the existing record, it uploads duplicate records instead (even though I have set my ‘Primary Key’ column in Bubble).

When I try any other method offered in (PUT, PATCH, or DELETE), I get the following error in Parabola:
“body”: {
“message”: “Unrecognized method. Currently supported: get,post”,
“status”: “ERROR”
“statusCode”: 405

Since the Bubble/Parabola documentation seems to indicate it is possible to update existing records, can you please help me understand how I might accomplish that?

Thank you!

Hi there - That’s an interesting error message. The Bubble API definitely supports modifying a thing with the PATCH method.

Check the section, “Modify a Thing by ID” in Bubble’s API docs.

Does your endpoint URL and your body seem to match Bubble’s documentation? If you’re able to share a screenshot of how your Send to an API step is currently configured, that’ll be helpful!

Thanks a bunch for the fast reply! I was under the impression the PATCH would base base its match-up (unique key) on the ‘Primary’ field as set in Bubble. But upon reading the link you shared a second time, I’m realizing the match-up is based on the ID number of the record.

Therefore, it sounds like it should work if I first use Bubble Import step (GET) to retrieve the ID numbers of all records, then use the JOIN step to apply any changes to the data that I want, and then finally use the Bubble Export step (PATCH) to write it back to Bubble for each ID.

I’ll try it out. Thanks a bunch!

Yes, exactly. That should work!