CitizenC
Windmill7mo ago
Citizen

MySQL script - Argument support list

Hello,

I have a MySQL script, and I wish to used named arguments :

-- database f/main/my_database
-- :ids (string[]) <-- Doesn't work, same for (int[])
-- :begin_date (string)
-- :end_date (string)

select *
from my_table t
where t.id in (:ids)
  and t.date between :begin_date and :end_date


My issue is I don't know how to name my type in order to support arrays (or list),

Can you help me ?

I can't find the official documentation in this page https://www.windmill.dev/docs/getting_started/scripts_quickstart/sql#mysql-1

Thank you for your time !
In this quick start guide, we will write our first script in SQL. We will see how to connect a Windmill instance to an external SQL service and then send queries to the database using Windmill Scripts.
Was this page helpful?