Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount.
Register nowGet certified as a Fabric Data Engineer: Check your eligibility for a 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700. Get started
we are trying to concatinate three strings including " in it, but Azure data factory adding as ". Question is how do we get rid of \ character. I Have one set variable returning value ABCDEFG and I wanted to concatenate with other data to populate like below in a variable. {"value"}:{"ABCDEFG"}
I am using the syntax in set variable like @replace(concat('{','"','value:',variables('requiredvalue'),'}'),'\ ','') and I am getting output value as "value": "{"value:ABCDEFG}"
Appreciate for help
I am using the syntax in set variable like @replace(concat('{','"','value:',variables('requiredvalue'),'}'),'\ ','') and I am getting output value as "value": "{"value:ABCDEFG}"
expected output {"value"}:{"ABCDEFG"}
Solved! Go to Solution.
Hello @krishn ,
We haven’t heard from you on the last response and was just checking back to see if you have a resolution yet.
In case if you have any resolution please do share that same with the community as it can be helpful to others .
Otherwise, will respond back with the more details and we will try to help .
Hi Team, as per the recommendation it is not required to eliminate \ special character from string. But we observed these special characters are printing when we copy it to CSV/text file in Blob storage. As long as value stay in Azure environment we do not have to worry about \ character. We are working on alternatives. Appreciate for help.
Apologies for delay, we validated the same and re-produced same result. Within the application it is excluding \ character however if we print this to a csv or txt file in blob object it is still printing the \ character. Seems we have to use StoredProcedure or Databricks activities to pars string. Appreciate for help.
Hi @krishn ,
Glad to know that you got some insights.
Please continue using Fabric Community on your further queries.
Hi @krishn ,
Thanks for using Fabric Community.
Can you please try this expression?
@concat('{"value"}:{"', variables('requiredvalue'), '"}')
Let me know if this works or not?
I tried this in first place but we are betting the below resule added \ to it, we also validated priting the same string but is still there. Ultimately we wanted to get rid of \ added
"{\"value\"}:{\"ABCDEFG\"}"
Hi @krishn ,
\ is an escape sequence inorder to preserve " in string and it will not include when you print the output.
Escape Sequences | Microsoft Learn
For Example:
Hope this is helpful. Please let me know incase of further queries.
This is helpful, so we are planning to pass this variable to another web activity as input variable as a parameter in relative string. So we don't have to exclude \ correct. Appreciate.
Yes there is no need to exclude \ as this is considered as escape sequence. Inorder to achieve your goal, you can use this -
@concat('{"value"}:{"', variables('requiredvalue'), '"}')
I hope this answers your query. Please let me know incase if you have further queries.
Hi @krishn ,
We haven’t heard from you on the last response and was just checking back to see if your query was answered.
Otherwise, will respond back with the more details and we will try to help .
Hello @krishn ,
We haven’t heard from you on the last response and was just checking back to see if you have a resolution yet.
In case if you have any resolution please do share that same with the community as it can be helpful to others .
Otherwise, will respond back with the more details and we will try to help .
Hi Team, as per the recommendation it is not required to eliminate \ special character from string. But we observed these special characters are printing when we copy it to CSV/text file in Blob storage. As long as value stay in Azure environment we do not have to worry about \ character. We are working on alternatives. Appreciate for help.