Hacker News new | ask | show | jobs
by roenxi 1003 days ago
> If you program defensively you can save on certain common Schema updates in e.g. a document based data model (e.g. adding more fields)

ALTER TABLE whatever ADD COLUMN new_field type DEFAULT NULL;

I've seen a lot of people claim that they don't want to waste time clarifying their schema and I'm sure there are edge cases where that is clever. But, in the majority of cases, they are literally risking data integrity for a saving smaller than the time it takes to write a HN comment.

Making schema implicit doesn't "save" anything. The schema is still there, now just only insiders who are completely familiar with the code know what it is. And they're going to have a few extra bugs because they'll forget too.