There are a number of things I would need to know about your project to feel comfortable recommending one framework, module, or approach over another, but I'll try and explain DBIx::Class so you can make a decision on how to proceed.

First thing to do is to create the object code which will let you access the data and give you back DBIx::Class objects. In DBIx:Class, a table = a DBIx::Class::ResultSource. So what the commands below do is look at your database schemas and create the code which will let you access each table as a ResultSource. Great, now you have a way to get all of the objects (rows) from each ResultSource (table). Any time you ask the database for some data, you will now get back a DBIx::Class::ResultSet.

Now, in your application you can do whatever you need with each ResultSource - maybe you do some stuff in memory and print a report, maybe you create another database and import all of your data into a unified schema, I'm not sure what your goal is, but hopefully this helps you understand how DBIx::Class may help you.

dbicdump -o dump_directory=./lib -o preserve_case=1 MyApp::MySQLSchema + dbi:mysql:DB_Name user password dbicdump -o dump_directory=./lib -o preserve_case=1 MyApp::OracleSchem +a dbi:oracle:DB_Name user password
use MyApp::MySQLSchema ; use MyApp::OracleSchema ; our $schema_mysql = MyApp::MySQLSchema->connect( sub { # code that ret +urns a DBI handle } ) ; our $schema_oracle = MyApp::OracleSchema->connect( sub { # code that r +eturns another DBI handle } ) ; my $company = $schema_mysql->resultset('Company')->find($company_id) ; + # get 1 row/object my $widget = $company->find_related('widgets', $widget_id) ; # get 1 r +elated row/object my $parts = $widget->search_related('widget_parts', { in_stock => 1 }) + ; # get all matching related rows/object my $r = $widget->create_related('widget_part', { # create a row comments => $comments, creation_time => time(), }) ; $schema_mysql->txn_do( sub { $r->insert() ; $r->update() ; }) ;

In reply to Re^3: DBIx::Class and Google Fusion Tables by onelesd
in thread DBIx::Class and Google Fusion Tables by SineSwiper

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.