Re:Get to know your ORM and take control of joins.
by RHSeeger on Wednesday July 18, 2012 @01:24PM
(#4261780)
I tend to find ORMs fantastically useful when working with code for front end web sites (ie, just reading data in simple ways) and raw SQL more useful when working on back end/business logic code. Specifically, if I'm going to need to do complex joins, inserts, updates, etc I'll use raw SQL... if I'm going to just read data I'll use an ORM.
I'll admit, though, that I'm a big fan of having a separate table that has the "front end view" (read: denormalized) of the data for the ORM to read from, especially in cases where the raw data tables are fairly complex.
I'll admit, though, that I'm a big fan of having a separate table that has the "front end view" (read: denormalized) of the data for the ORM to read from, especially in cases where the raw data tables are fairly complex.