[Dbix-class] Class::DBI => DBIx::Class.
Will Hawes
info at whawes.co.uk
Sat Jan 21 11:19:56 CET 2006
Todd Lorenz wrote:
> I've seen a lot of the Class::DBI vs. DBIx::Class stuff going back and
> forth, and I'm getting the feeling that DBIx::Class is becoming a better
> and better choice for someone making his first foray into ORM-land.
> Obviously DBIx::Class has the great advantage of having learned from
> Class::DBI's mistakes.
>
> But I've been using Class::DBI for a long time now, though; I know it, I
> live it, I even love it a little. The problem of course is that the more
> code I churn out using Class::DBI, the harder it's going to be to refit
> everything when DBIx::Class becomes a fruit too juicy to resist. So
> about this compat layer...
>
> What *doesn't* it do? Has anyone tried it out on great big piles of CDBI
> production code? Does there exist any document that might help a guy
> wean his code off the compat layer systematically? Or is it still too
> early to worry about any of this?
>
> TRL
DBIx::Class is already in production use by quite a few people and there
haven't been any disasters yet :)
You get better performance, plus improved functionality including built
in paging, multi-column primary keys and grouping.
Porting code from CDBI is very straightforward for simple cases - all it
really involves is changing some syntax for your model classes and
possibly a few lines of template code. If your model classes are
generated by Loader, there may be even less to do ;)
If you have a lot of set_sql statements, there is a bit more work but
afaik there hasn't been an SQL yet that couldn't be done in DBIC.
Triggers are not supported, as it is currently felt that they are not
necessary.
Discussion, feature requests, bugs, problems, etc please visit
#dbix-class at irc.perl.org.
More information about the Dbix-class
mailing list