hugsql
hugsql copied to clipboard
Bulk update?
trafficstars
I'm trying to bulk update multiple rows in same query.
Update table set "value"= case id when 1 then "one" when 2 then "two" end where id in (1,2)
something like that
@talatarazi1 Is this valid SQL? Please make sure your SQL runs correctly on your database first. After that, please provide more information with the HugSQL query that you are using, how you are calling the generated HugSQL function (with passed in parameters), and any error message that you are encountering.