mind explaining?
olafurp@lemmy.world 1 year ago
Always SELECT first. No exceptions.
adrian783@lemmy.world 1 year ago
nailbar@sopuli.xyz 1 year ago
By running a select query first, you get a nice list of the rows you are going to change. If the list is the entire set, you’ll likely notice.
If it looks good, you run the update query using the same where clause.
But that’s for manual changes. OP’s update statement looks like it might be generated from code, in which case this wouldn’t have helped.
drekly@lemmy.world 1 year ago
I did when I made the query a year ago. Dumdum sleep deprived brain thought it would look more organised this way
Dark_Arc@social.packetloss.gg 1 year ago
Better yet… Always use a transaction and have backups.