Business::DPD::DBIC - DBIc::Class Interface to DPD data
use Business::DPD::DBIC; my $sqlite_file = Business::DPD::DBIC->path_to_sqlite
A DBIx::Class based interface to various data sources needed to generate DPD labels.
Business::DPD::DBIC->import_data_into_sqlite({ schema => 'Business::DPD::DBIC::Schema', source => '/path/to/data', connect => [ DBI connect info ] });
Parses the plain text database provided by DPD and stores it into the database used by Business::DPD (which defaults to the build-in sqlite DB)
Business::DPD::DBIC->import_data( $schema , { source => '/path/to/data', });
Import the plain text data into the <$schema>. Usefull if you want to embed the DB into your own database.
my $sqlite_file = Business::DPD::DBIC->path_to_sqlite;
Returns the absolute path to the SQLite DB. You most likely won't need this...
Business::DPD::DBIC->generate_sqlite;
Generates a new sqlite DB and fills it with the data included in this dist.
Dies if a DB already exists.
my $list_of_create_statements = Business::DPD::DBIC->create_table_statements;
Returns an ARRAYREF consisting of plain text sql statements to create the database. If you want to embed the DB, you might want to munge the values to fit your database.
RevDev <we {at} revdev.at>
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install Business::DPD, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Business::DPD
CPAN shell
perl -MCPAN -e shell install Business::DPD
For more information on module installation, please visit the detailed CPAN module installation guide.