[Catalyst] DBIC and RDBO compared (was: Choosing the right ORM)

John Siracusa siracusa at mindspring.com
Thu Dec 1 03:17:17 CET 2005


On 11/30/05 9:05 PM, Perrin Harkins wrote:
>> When you use CDBI to do custom queries, do you make sure that the columns
>> returned match the expectations of your CDBI class?
> 
> Yes.
> 
>> If so, then my commented-out get_objects_from_sql() method does the same
>> thing.
> 
> Sounds pretty similar to what I do with Class::DBI.

Hm, then I guess I'll uncomment it for the next release.  It does save a lot
of boilerplate typing in this particular situation.

>> Also, I only used prepare_cached() in the places where I expect the SQL to
>> be identical over time: things like save() and delete().  I don't use it at
>> all in the Manager, where each query can be different.
> 
> I would still use it there, maybe with a switch to disable it.  Most
> applications have a specific range of queries that they repeat, and it's
> typically a pretty small set.

That sounds reasonable.  Next release, probably.

-John





More information about the Catalyst mailing list