Here’s a comment I made in an outgoing email. It’s a conclusion, the beginning of an essay I might write one day, and something I’d be happy to be convinced is wrong, given all of the resources the world is pouring into persistence systems: “My experience with OO is that ‘objects shouldn’t also be data’. The temptation to throw away SQL is just too high, and people tend to implement very boring things because a SQL join, the source of many of the more interesting things you can do, is too ‘advanced’.” Two-way joins are in fact pretty commonly supported, but this is still baby steps in terms of SQL’s full power. And of course many (most?) persistence engines have an escape hatch where you can write your own SQL, but once you buy into the design philosophy of these persistence tools, escaping to SQL feels wrong.

%d bloggers like this: