Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Are people really not using inheritance? I think of that as the main reason to choose postgres over a non-ORDBM


I don't mind nullable columns and would rather my ORM handle inheritance.


We would (we don't even use an ORM but find we have some relations that would benefit from inheritance), but lack of FK support kills it. Instead we either break out common fields to a separate table (which makes it difficult to enforce row constraints), or put all fields in a single table and make them NULLable (sometimes with a constraint to ensure the NULLs match expected usage).


Lots of limitations. The main one is if you're using FKs in your database, you're quickly going to hit issues: https://www.postgresql.org/docs/current/static/ddl-inherit.h...




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: