Are you sure the DSN is right? i.e., are you able to use $dbh for anything else? Since the do() returns 1, it sounds like a transaction issue, but i see that you have
AutoCommit => 1 in there.. a blind stab, but try
$dbh->commit after the do() ...
As for side notes, a couple things came to mind:
(The last two may not be needed/appropriate in your case, but definitely very good tools to be aware of.)
Update: I just read jZed's post, which has the very good point about $rows .. I guess i assumed it was 1 -- you should print it to confirm if it's 1 or 0E0 .. if the latter, then i would turn attention to $dat
1 and confirm that it really has the desired value..
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: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.