I'm using DBVisualiser to run the following script (Expecting to pass variable in query and retrieve data based on where condition)
set Id='1';
select * from MyTable where account_id = '${hivevar:Id}' limit 5
Unfortunatelly, when I run this script I see that query which is executed is as follows:
set Id='1';
select * from mytable where account_id = '${hivevar:Id}' limit 5
But when I run query with hardcoded value
select * from mytable where account_id = '1' limit 5
then I get expected dataset. I would apprecaie if anyone could help me to learn what I do wrong.
Thanks in advance.