News for hackers. Stuff that matters.
Re:An UPDATE without a WHERE, or something close to it by mprovost on Friday October 29, 2021 @10:41AM (#29039005)
The issue is that these declarative languages (SQL, Terraform, Cisco IOS...) abstract away the loop. Sure it's tedious to do the same operation to 1000 servers, but computers are good at loops. And computers can help write loops. At previous jobs we had tools that would generate lists of servers based on different parameters and then you could pipe that list to a command to do some operation across the whole list. But it gave you the chance to generate the list first and make sure that it looked accurate. If you were expecting to update the 10 webservers but there are 1000 lines in the file, you know something went wrong. I suppose the other issue with these languages is that they often substitute a lack of a list for "everything" instead of an empty list that does nothing.

There are no comments on this comment yet.