Remix.run Logo
lock1 a day ago

What if almost everything is NULLABLE? including the supposedly primary key and foreign keys of the table?

I've had the firsthand experience building a consumer for that kind of DB and it's hell to get anything running correctly without literally writing a dedicated layer to sanity check everything.

gopher_space a day ago | parent | next [-]

> without literally writing a dedicated layer to sanity check everything

It's not attractive to developers for a variety of reasons, but encapsulation is generally cheaper (in every sense) than the alternatives by orders of magnitude. If a system is hard to alter and other people rely on it to do their jobs, thinking about it as set in stone during my planning process will save me grief and heartache.

Starting with an independent client in mind makes it easier to plan around things like reconstructing tables from composed exports or dealing with authoritatively incorrect data. It's a good collection point for hard-coded edge case handling, and a great location for all of your discovery notes.

phplovesong a day ago | parent | prev [-]

Sounds like a bad domain, and/or poor design.