SQL only provides for updating a row or rows with one set of values. Assuming that you're revising your array with different values per row, there's no way to do this except to iterate the array and do an Update action per row.
Inserting is a different situation, since INSERT's VALUES clause can take multiple value sets. TeraScript doesn't help you do this, however, so you have to write a custom query. I plan to add a multi-insert action in the future. I'm not sure if I would ever support a multi-update action since it would rely on some convention, such as the first column being the primary key. Robert From: Fogelson, Steve [mailto:[email protected]] Sent: Monday, October 14, 2019 6:30 PM To: [email protected] Subject: TeraScript-Talk: Writing array back into MySQL DB I use MySQL for my DB. If you read a set of data into an array, can you write the revised array back to the DB with one write or do you need to write back a row at a time? If you can, how? Thanks Steve Fogelson Internet Commerce Solutions _____ To unsubscribe from this list, please send an email to <mailto:[email protected]> [email protected] with "unsubscribe terascript-talk" in the body. ---------------------------------------- To unsubscribe from this list, please send an email to [email protected] with "unsubscribe terascript-talk" in the body.
