News for hackers. Stuff that matters.
Re:Making Database Systems Usable by sa46 on Wednesday August 21, 2024 @01:55AM (#41307182)
Composite types can be atomic--a string is a composite type. The point (123, 456) is a composite type but is atomic.

Good discussion at https://dba.stackexchange.com/questions/2342/what-is-atomic-...

Re:Making Database Systems Usable by sgarland on Wednesday August 21, 2024 @08:39AM (#41309687)
Good point.

I’ll also add to my previous comment, that it’s fine to violate normal form if you are aware that you’re doing so, and have a good reason. There are some instances where an array happens to make excellent sense from a performance standpoint, for example, and storing it in RDBMS doesn’t magically make everything explode.

I do disagree with people’s tendency to shift towards treating RDBMS as a way to store schema in JSON, though. Not only is it massively unperformant, and indexing it is a pain, but you can quite easily get yourself into situations where there are multiple versions of your schema-within-a-schema, and that can be a nightmare.

Re:Making Database Systems Usable by josephg on Wednesday August 21, 2024 @10:36AM (#41310723)
I don't think I was clear above. I want embedded objects. I wish there was a more "database-native" way to do it than using JSON, and all the ugliness that JSON brings. (Like dynamic typing, schema-within-a-schema, more complex indexing & querying, etc.)

Sounds like something the databases should be able to provide natively, without needing to use JSON at all.

(And apparently support for this sort of stuff is slowly improving! Thanks to all the sibling comments for details!)