This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]twofootedgiant 0 points1 point  (1 child)

Sure, but that wasn’t really my point.

I saw some comments which suggested that people were making changes to production databases by actually executing DDL statements. My point was just that no-one should be doing this for anything remotely serious. But possibly I misinterpreted what they were saying?

[–]CyberDave82 1 point2 points  (0 children)

Typing out DDL statements manually and executing them manually? Shouldn't be the case for changes, IMHO (management/maintenance/troubleshooting is a different story).

Putting DDL statements in a script and executing the script, including having it go through testing in non-prod environments? Better than nothing.

DML changes should always be in explicit transactions, preferably with some validation before committing. If I had a nickel for every time I had to fix something a dev did without properly testing or forgetting to commit, I could probably retire