3 ms·
ORM is never about "not learning SQL". I am great at writing SQL, but i hate converting my resultset to object graph, converting lazy loading vs eager loading a
by tehlike 4y ago
ORM is never about "not learning SQL". I am great at writing SQL, but i hate converting my resultset to object graph, converting lazy loading vs eager loading at times, dealing with types and changing types etc.
On "great" side of things, Linq brought massive type safety to .net land, and made queries also compile time checked.
IS it leaky? yes. Every once in a while you'll need to write SQL.
Does it solve a lot of problems? Also yes.
Disclaimer: I was once a contributor to NHibernate.
- ozim 4y agoEspecially writing 80% of queries that are simple crud to update or read single table that needs to be written most of the time. Such a waste of time to maintain that conversion code by hand.
- yyyk 4y ago>LINQ... made queries also compile time checked Alas, it's far from a complete solution. It's too easy to type an expression that compiles but blows up at runtime because the underlying provider doesn't support it or gets confused.
- tehlike 4y agoThis is very true, when NHibernate was getting LINQ it was easy to trip its provider to throw an exception. But it was still great for majority of cases.