Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re^2: Whip Me, Beat Me, Make Me Use ORMs

by Ovid (Cardinal)
on Jun 29, 2007 at 15:36 UTC ( #624110=note: print w/ replies, xml ) Need Help??


in reply to Re: Whip Me, Beat Me, Make Me Use ORMs
in thread Whip Me, Beat Me, Make Me Use ORMs

merlyn is right. Rose is wicked fast. It's fast enough that you're unlikely to notice too much of a difference and it's easy to fine-tune, if needed. The wins with Rose (and its clean design), easily outweigh the losses.

You can see the benchmarks for yourself.

Cheers,
Ovid

New address of my CGI Course.


Comment on Re^2: Whip Me, Beat Me, Make Me Use ORMs
Re^3: Whip Me, Beat Me, Make Me Use ORMs
by lima1 (Curate) on Jun 29, 2007 at 16:16 UTC
    When you work with many tables and gigabytes of data, you have to fine-tune many queries. The last time I had these problems, this tuning was not that easy because an ORM is kind of a blackbox - RDO probably less than others. I ended up with ugly code that was not more maintainable than plain DBI code. Well, probably I am someone who does silly things with ORMs ;)

    But I really like RDO, so I'd interested in reading more about things you should consider (probably starting with the db schema) when you go beyond little webapp databases ;)

      You're correct: complicated queries on large databases are no place for an ORM. Rose is pretty fast for simple-to-medium queries, but complex ones always require hand-tweaked SQL. You can run hand-written SQL through Rose though (or others), and it can still provide a convenient place to organize your custom queries and deal with your database handle/statement caching.

      I would also add that ORMs are never good for bulk updates. You can totally crush the speed of an ORM for a bulk insert/update by writing some simple DBI code or by using your database's bulk loading features, e.g. multi-row insert in MySQL.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://624110]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (4)
As of 2014-11-26 05:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My preferred Perl binaries come from:














    Results (162 votes), past polls