From: Alexander Hartmaier Date: Wed, 13 Jan 2010 16:28:05 +0000 (+0000) Subject: added the sources parser arg to the example code X-Git-Tag: v0.08116~58 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=37cb0de173eed31c34a583b1404fcef6f41da0ce;p=dbsrgits%2FDBIx-Class.git added the sources parser arg to the example code --- diff --git a/lib/SQL/Translator/Parser/DBIx/Class.pm b/lib/SQL/Translator/Parser/DBIx/Class.pm index 5d146f8..d67ce9e 100644 --- a/lib/SQL/Translator/Parser/DBIx/Class.pm +++ b/lib/SQL/Translator/Parser/DBIx/Class.pm @@ -379,7 +379,14 @@ from a DBIx::Class::Schema instance my $schema = MyApp::Schema->connect; my $trans = SQL::Translator->new ( parser => 'SQL::Translator::Parser::DBIx::Class', - parser_args => { package => $schema }, + parser_args => { + package => $schema, + # to explicitly specify which ResultSources are to be parsed + sources => [qw/ + Artist + CD + /], + }, producer => 'SQLite', ) or die SQL::Translator->error; my $out = $trans->translate() or die $trans->error;