[Dbix-class] Patch for SQL::Translator::Parser::DBIx::Class
Matt S Trout
dbix-class at trout.me.uk
Sun Jun 25 21:39:05 CEST 2006
Sebastian Willert wrote:
> Hi all,
>
> after some late-night discussion with castaway about
> DBIC::Schema->deploy() we noticed that
> SQL::Translator::Parser::DBIx::Class tries to query the connected
> database. This shouldn't be done IMO because this might change the info
> provided in the schema and might not be stable between different
> underlying RDBMs.
>
> This are the reasons why I've produced the patch below, the changes
> should be self-explainatory. The patch has been tested on the
> command-line, using the programmatic interface of SQLT and using
> DBIC::Schema->deploy() but could need some additional testing with more
> complex schema then I have readily available.
The changes are clearly harmful. A schema class simply acts as a prototype for
objects of that class, it is not guaranteed to contain all the requisite data.
--
Matt S Trout Offering custom development, consultancy and support
Technical Director contracts for Catalyst, DBIx::Class and BAST. Contact
Shadowcat Systems Ltd. mst (at) shadowcatsystems.co.uk for more information
+ Help us build a better perl ORM: http://dbix-class.shadowcatsystems.co.uk/ +
More information about the Dbix-class
mailing list