Starting December 3, join live sessions with database experts and the Microsoft product team to learn just how easy it is to get started
Learn moreGet certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now
Hi,
In my paginated report, one of the parameters has input value as:
'abc,def,ghi'
but I want it to be parsed and make the parameter value as:
'abc','def','ghi'
So I can use these with IN
I tried
=Join(Split( Replace(Parameters!SiteIdList.Value, ",","','") ,"',"), ",")
But then powerbi adds escape character with my quotes making the output as :
'\'abc\',\'def\',\'ghi\'
which makes it useless.
Any suggestion
Solved! Go to Solution.
Yes, it was the data provider (Simba Odbc driver) that was escaping single qoute after I was replacing , with ','
Had to use expression in Query text to pass my complete query as a string which then worked.
Where are you seeing these escape characters? I just used the inner Replace() call from your example as the split then join seems redundant and I don't see any escaping going on. The top line below is the original parameter value and the bottom line is a text box using replace(). It possibly also depends how you are using this parameter are you concatenating it into your query with an expression or are you passing it into another parameter in the query? It could be the data provider doing the escaping to prevent SQL injection.
Yes, it was the data provider (Simba Odbc driver) that was escaping single qoute after I was replacing , with ','
Had to use expression in Query text to pass my complete query as a string which then worked.
Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.
User | Count |
---|---|
3 | |
2 | |
1 | |
1 | |
1 |
User | Count |
---|---|
6 | |
4 | |
4 | |
3 | |
3 |