I have some raw JSON data which I need to insert into my SQL database. I am able to read the data using a Lookup activity but am facing difficulties with the SQL insert as some of the fields in the JSON contain apostrophes ('). In python, I am able to easily account for this using re.sub("'", "''", text) but I cannot seem to find a way to do this in my AzureSynapse pipeline. Azure does not allow me to use double quotes (") in the replace() function so I am unable to do something like replace(text, "'", "''").
Is there a way to catch and replace single quotes with two single quotes in the AzureSynapse pipeline? Maybe an escape character in the replace function that allows me to use the single quote without closing the string?
Many thanks for any help!