I've created a macro and am using it in the WHERE condition of a control, but the quotes of my sub query keep getting doubled.
SELECT [ItemID] FROM Func_Selection_ParseIDs(REPLACE(MyUniselectorColumn, '';'', '',''))
My code looks like this, but I've also tried building it as a plain string -- same result.
//Replace clause for delimeter, if not a comma
string toParse = delimeter == "," ? column : "REPLACE(" + column + ", '" + delimeter + "', ',')";
//Create the query
var query = new DataQuery();
query.Column("ItemID");
query.From("Func_Selection_ParseIDs(" + toParse + ")");
return query;
If I write the same query directly in the WHERE field, it works fine. Not sure what's causing those double quotes or how to avoid them.