[Dbix-class] Schema export

Bernhard Graf dbic at augensalat.de
Thu Mar 2 00:08:07 CET 2006


Cookbook tells:

"To create a MySQL database from an existing DBIx::Class schema, convert
the schema to MySQL's dialect of SQL:

sqlt --from DBIx::Class --to MySQL --DBIx::Class "MySchema.pm" > Schema1.sql

This does not work.
First of all the --DBIx::Class argument is obviously not valid.

sqlt --from DBIx::Class --to MySQL "MySchema.pm" > Schema1.sql
spits out:

Error: translate: Error with parser 'DBIx::Class': Undefined subroutine
&DBIx::Class::parse called at
/usr/lib/perl5/vendor_perl/5.8.5/SQL/Translator.pm line 484.

What is the correct way?
-- 
Bernhard Graf



More information about the Dbix-class mailing list