A general purpose programming language should support parameterised tuple and relation types, and the operations of the relational algebra as first class citizens []
This would allow code like the following:
auto R1 = relation<int x, int y>{ {(x,1), (y,2)}, {(x,1), (y,5)} }; auto R2 = relation<int y, int z>{ {(y,2), (z,10)}, {(y,2), (z,20)}, {(y,3), (z,4)} }; auto R3 = PROJECT<x,z>((R1 JOIN R2) WHERE x>0);
and the compiler deduces the type of R3.
This approach eliminates the need for an O/R Mapping, and the limitations involved with using OO to manage collections of facts.