[Dbix-class] Patch for SQL::Translator::Parser::DBIx::Class

Matt S Trout dbix-class at trout.me.uk
Mon Jun 26 15:35:11 CEST 2006

Sebastian Willert wrote:
> Actually, that was kind of my initial intention, after I ran into
> trouble using deploy(), which seems to need a run-time connection before
> being called. (Regarding your next post: the problems might have easily
> been caused by missing data_types in the schema, yes)

Well, that's what deploy() is *for* - deploying to the database you're 
connected to.

If you're trying to just generate the .sql file then you want either 
create_deployment_statements or the new create_ddl_dir in -current.

> If this is the case, the correct approach would be to warn (or even
> die?) in SQLT::Parser::DBIC in a situation where data_type is unknown
> and no table information can be retrieved? And some docs regarding
> SQLT::Parser::DBIC, DBIC::Schema::deploy() and about testing schemas in
> general?

Good thought, and yes please.

> I think I could try to do some of this, but I've seen that my
> understanding of DBIC still sucks, so I am not very confident :(

Nah, you just missed out on a particular subtlety. In any case, while 
incomplete/incorrect docs on CPAN might be a bad thing the phrase "you've got 
to start somewhere" springs to mind - and we'd be more than happy to help with 
editing, tweaking and corrections. Make a start, RFC it to the list and see 
what people think - worst case scenario you've learned more about DBIC :)

      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