Hi, I'm making a query JSON with SQL (all the operations are made based on an imported CSV file, so there is no need for a Database) and I'm trying to use a drop down Select as a way to use its value as a column name in a query, like this:
SELECT * FROM {{tableSource.data}}
where {{selEmail.value}} = '%gmail.com'
I read that the correct way to do this is using {{"'"+selEmail.value+"'"}} or '{{selEmail.value}}' and that I need to "Disable converting queries to prepared statements" in the resource option, but how can I do so with Query JSON with SQL? As far as I can see there is no way to edit this type of resource.
Maybe it's disabled by default and I'm making some kind of error?
Hi @ugo.ago , thanks for the reply and sorry for being a bit late, but this is not quite what I was looking for.
What I'm trying to do is to let the user decide on which column the query should operate.
This is because I noted that if the column names in the CSV file aren't EXACTLY like in the query, the query won't find anything in the file and result in an empty table.
All this is just so that anytime a user needs to use the app they don't need to enter the file and change the column names every single time.
Essentially, is kinda like field mapping.
Here I made a little mockup for the app showing better what it does: video