Updating multiple rows with same value

How do I go about updating multiple rows of data in MySql with same values. I have a query which pull multiple rows in a lot and bin. I would like to create a transfer button that changes the rows to a new lot and location. What I have doesn’t work on multiple rows.

system.db.runPrepUpdate(“UPDATE roughstorage SET LBin = ?, Llot = ? WHERE LBin = ? and Llot = ?”, [newLBin, newLlot, LBin, Llot] , “Progress”)

I tried a similar query on one of my MsSQL tables and it worked fine: updated 2 different columns across 3 rows.

Does it throw any errors on the client or gateway?

Some other things to check:
Do you have write access within Ignition? (single updates work?)
If it’s a Progress OpenEdge DB, is the query syntax any different from standard SQL?

1 Like