On 5/23/16 10:30 PM, Craig Ringer wrote:
I find it notable that no popular ORM has bothered adopting PostgreSQL's
inheritance features, and instead just use big left joins or repeated
SELECTs to implement parent/child relationships, with foreign keys
Since when do we consider ORMs to be an example of how to do good
In this case, I'm sure no ORM uses the feature because either the ORM's
authors have no clue it exists (except maybe for partitioning) or
because we're the only mainstream database that has it.
I consider inheritance mostly useless without the ability to have UNIQUE
indexes that span a parent relation and all its children. You can use
them for partitioning only by sacrificing a bunch of integrity
protection or creating messy chains of FKs between individual partitions.
There's ways around this issue, but I agree that it's a very unhappy
situation right now.
I'd rather like to quietly deprecate inheritance and eventually remove
it once we have real partitioning and some time has passed...
IMO that's a very unfortunate attitude to have for the "Worlds Most
Advanced Open Source Database". Now that OO programming isn't treated as
a magic bullet it's proven to be an extremely powerful tool, especially
when used to encapsulate complex data. The
ndarray->Series->DataFrame->Panel inheritance tree is a great example of
this. Feature-wise, we need to be doing *more* of this kind of work, not
less. Lack of support for OO paradigms was one of the drivers for NoSQL.
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Experts in Analytics, Data Architecture and PostgreSQL
Data in Trouble? Get it in Treble! http://BlueTreble.com
855-TREBLE2 (855-873-2532) mobile: 512-569-9461
Sent via pgsql-hackers mailing list (email@example.com)
To make changes to your subscription: