On Sun, 22 Sep 2013 12:41:26 GMT, Sönke Ludwig wrote:

On Sat, 21 Sep 2013 10:57:18 GMT, simendsjo wrote:

On Sat, 21 Sep 2013 10:27:16 GMT, Sönke Ludwig wrote:

Btw. did you already look at hibernated? It seems to be on hold for a while now, though, and misses a patch to use the latest mysql-native version.

No, haven't looked at it. If it works like hibernate or other ORMs, it will either fetch a lot of stuff when I don't need it, or lazily go to the database whenever I access fields..
I've used NHibernate on several projects in the past, but I would rather just use something very simple so I can control exactly what gets fetched - kind of constrained by resources here :)

Hm that sounds like a reasonable objection, indeed. I wanted to try a hibernate like model for some time, but this makes me worry a bit now, at least for some applications. Especially if the API lacks manual intervention for the cases where it really becomes critical.

ORMs is really tempting as it removes a lot of potential errors and removed a lot of duplication. I think all larger frameworks have ways of writing SQL manually when you need to, but if you want performance, you'll end up working around the framework at every corner and loosing most of the benefits.

I'll no longer use an ORM for those reasons :/
But I'll experiment a bit with this in D - pretty sure it's possible to get something more minimal while experiencing some of the advantages of ORM.