Please create an account to participate in the Slashdot moderation system

 



Forgot your password?
typodupeerror

Slashdot videos: Now with more Slashdot!

  • View

  • Discuss

  • Share

We've improved Slashdot's video section; now you can view our video interviews, product close-ups and site visits with all the usual Slashdot options to comment, share, etc. No more walled garden! It's a work in progress -- we hope you'll check it out (Learn more about the recent updates).

×

Comment: Re:ORM == good (Score 1) 65

by mixmasterjake (#19818699) Attached to: Canonical Begins To Open-Source Launchpad
My personal feelings is that an ORM makes the easy stuff easier and the difficult more difficult. Dealing with aggregate queries, complex joins and huge datasets requires a good knowledge of the ORM and how it generates SQL. If you're used to having direct access to the DB, getting the ORM to do the proper magic can be frustrating.

This code you posted, though, would be bad regardless of using an ORM or not. I've seen the same thing using regular SQL to grab all the rows and then filtering them out in a code loop. This is just bad, un-scalable code in general. The right way to do this with an ORM is to just use it's expression or criteria functionality to do the filtering instead of grabbing all the records.

"Nature is very un-American. Nature never hurries." -- William George Jordan

Working...