Hi,
I am trying to use a named query to update a value in one of four columns in a MySQL database table. However it looks like if I use a string parameter to tell the query the field to update it doesn't work. The value parameter works fine.
![image](https://global.discourse-cdn.com/inductiveautomation/original/3X/d/0/d06dc9c10fd2ab478d585068dff051372ab5d80a.png)
![image](https://global.discourse-cdn.com/inductiveautomation/original/3X/2/3/232316830ce20432b8b976bfc99996fdfb4bffcc.png)
Is this possible at all?
Did not find this case in any of the other topics...
Thanks.
edited typo
Change Type
from Value
to QueryString
and re-drag the parameter into the query. Be careful as the inputs are not sanitized
Use type QueryString:
![image](https://global.discourse-cdn.com/inductiveautomation/original/3X/e/5/e546b4c21ad025ef41659e7eff67d300097497af.png)
Then:
SET
{entryName} = :entryValue
...but beware of SQL injection--don't do it if entryName is generated by user input!
2 Likes
Thank you so much! Don't know why I looked at forum first. Thanks for the time. D
1 Like