News for hackers. Stuff that matters.
Re:What ORMs have taught me: just learn SQL (2014) by pjmlp on Monday December 18, 2017 @06:24AM (#15950898)
I can get very creative with SELECTs, making use of Prolog style queries, which are fully done server side on the database.

Most ORMs will download all the data and evaluate them on the client side, with code that is even more convoluted that the SQL one and thus with less performance.

Re:What ORMs have taught me: just learn SQL (2014) by scarface74 on Monday December 18, 2017 @06:52AM (#15951023)
If your ORM is downloading all of your data and querying client side, then your ORM "is doing it wrong".

Entity Framework and any other Linq to data provider translates the Linq expression to the native language of the source data and does it server side.

Re:What ORMs have taught me: just learn SQL (2014) by pjmlp on Monday December 18, 2017 @07:15AM (#15951111)
I know EF, which is why my comment also mentions "code that is even more convoluted that the SQL one and thus with less performance".

LINQ only allows for a fraction of what is possible with SQL, and good luck having the best queries generated out of it, if the RDMS doesn't happen to be SQL Server.

Re:What ORMs have taught me: just learn SQL (2014) by scarface74 on Monday December 18, 2017 @07:49AM (#15951253)
Actually my DMS is sometimes Mongo and the Mongo driver does pretty well at translating Linq to Mongo Query using the aggregation framework.

It all depends on the talent of the authors of the drivers.

Re:What ORMs have taught me: just learn SQL (2014) by zzzeek on Monday December 18, 2017 @04:12PM (#15955559)
> Most ORMs will download all the data and evaluate them on the client side

I've seen that pattern in lots of homegrown applications, but I've never seen such a thing in a mainstream ORM. Care to provide examples ?

Re:What ORMs have taught me: just learn SQL (2014) by pjmlp on Tuesday December 19, 2017 @02:56AM (#15958518)
I've seen it a lot in entity beans and the early days of hibernate.

Nowadays I only bother with Dapper, MyBatis, using a mix of SQL and stored procedures.

EF only if the RDMS happens to be SQL Server.