Hello

Question I"m stumped on here, I can't see any way to represent my database via Class::DBI.

My database holds summaries of unique network transactions, split into monthly, trans per day tables, within yearly schemas. Each row is actually a summary of any identical transactions that happened for that day with a count column

There are a few lookup tables for strings that otherwise might repeat in the transaction record like username -> user id etc. Those lookup tables are also held within the yearly schema for each year 2007.usernames etc. (so yes small amount of repeat data per schema).

I'm writing a cgi to allow queries on these over a date range using about any combination of criteria from the transaction. Ex , date, username, item requested, request method etc

I can't figure out how to represent this via Class::DBI because of the multiple tables holding transaction summaries.

Class::DBI seems to only support something like

Transactions ------------ One Huge Table usernames ---------- One Huge Table When it's ------------ 2004.jan_trans_daily 2004.feb_trans_daily 2004.usernames .. 2007.jan_trans_daily 2007.feb_trans_daily 2007.usernames
etc

Can someone enlighten me if there's a clean way to do this? Or is it better to just manually code all the sql.

thank you in advance
K


In reply to Class::DBI and data split multiple tables by kor

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.