MySQL query based on Input not working

Hey, I'm a very new retool user, I'm sure I am messing something up here somewhere...

I am trying to do a very simple MySQL query and return all results. The catch or the weird part is that the where statement needs a value defined by an input...
this query:
"select * from server_wipe_data where wipethur = 1;"
has a column for each day, it is a boolean field (ive tried a bunch of others too)... if i run that query which i copied from the retool tooltip and pasted into my MySQL console (without the quotes) it returns the expected results...

However if i run the workflow:
select * from server_wipe_data where {{}} = 1;
Mysql returns an empty result.

Ive hardcoded the code block to return {wipecolumn: "wipethur"} for now.

Heres the hardcoded query working fine:

Hey @XeryaX! In order to get this to work I believe you have to disable prepared statements on the resource.

Amazing, thank you! I was looking for something like this within the workflow, not on the resource itself!

1 Like