I am using a notebook, and I have an array, but I am struggling to use the SQL query. So the list_of_tx is the array of values.
I have look at the markdown, and the SQL queries looks fine to me, but I just not able to use the SQL query functionality on the notebook. It is returning empty values.
SELECT *
FROM table
WHERE txn IN (${list_of_tx.map(tx => `'${tx}'`).join(', ')})
Observable doesn’t seem to like it when I tried to create a let variable to update the array. So, I have been having trouble in doing that.
What I was trying to achieve was to set some if conditions, and if true, add extra element to the array. Then used that array in the IN operators to filter the DB.