Hi! I´m trying to do the following query with the "query database" smart service:
UPDATE CPF_LINEAS_PEDIDOSET FACTURADA = true where ID_PEDIDO = ac!pedido and MATERIAL = ac!Material
The variable ac!Material can be multiple (f.example Material 1, Material 2). This is because in a previous step in the process model, the user can enter several rows.
Because of using a list of string in the clause "WHERE" (I´m using it as a filter), I think I´m returning the following error:
How can I fix this? Thanks a lot!
Discussion posts and replies are publicly visible
SQL should look like this:
SELECT item FROM TABLE WHERE field IN ('item1', 'item2', 'item2')
To generate the items:
joinarray( a!forEach( items: { "item 1", "item 2", "item 3" }, expression: concat("'", fv!item, "'") ), "," )