I’ve got a query
SELECT
*
FROM
table
WHERE
product_id IN ({{ "'"+transformer.value.join("','")+"'" }})
But I can't get it to work. transformer.value
returns an array of strings. The strings look like this: gid://shopify/Product/8492752863571
. See the screenshot below:
In the database I know there's a row with column product_id set to gid://shopify/Product/8492752863571
. But still I get zero results.
When I copy the actual query it does give me 3 results:
SELECT
*
FROM
table
WHERE
product_id IN ('gid://shopify/Product/5946903756950',
'gid://shopify/Product/7964207579362',
'gid://shopify/Product/7964208038114','gid://shopify/Product/7964209545442',
'gid://shopify/Product/7964209938658','gid://shopify/Product/7964211478754',
'gid://shopify/Product/7964211544290','gid://shopify/Product/7964211904738'......
seems like nothing gives me results except by running the query without {{ }}
variables and just write the query by hand like here above. Anyone got a solution, alternative approach or more insight in what I'm doing wrong?