Ok I am at a loss I have a query that work in one perl program but not in the other, I have stripped the code down to the bare essentials and have looked for any differences between the one that works and the one that does not but can find no problems. I get an Oracle error on this, if I select on a given field no error but the print only returns info if the data is half or less of the column size.... Am I missing something obvious here ????
#!/usr/bin/perl use DBI; my @listOfPaths; my @listOfNames; my %dbf; my $linkpage; my %rels=(); my %relsdt=(); my %vals=(); my $dbh; $ENV{"ORACLE_HOME"}="ORACLE_HOME=/oravl01/oracle/8.0.6/"; $ENV{"TWO_TASK"}="nxt1"; &sqlConnect("alan1", "alan1"); &getRef; &sqlDisconnect; ###################################################################### +############# sub sqlConnect() { $connectString=join '/', $_[0], $_[1]; $dbh = DBI->connect('dbi:Oracle:',$connectString); unless ($dbh) { &showSQLError($DBI::errstr); } } ###################################################################### +############# sub sqlDisconnect() { $dbh->disconnect; } ###################################################################### +############# sub getRef() { $statement = "select * from OPEN_ISSUES order by OI_REFERENCE asc" +; print "$statement\n"; $rqry = $dbh->prepare($statement) or &showSQLError($dbh->errstr); $rqry->execute or &showSQLError($DBI::errstr); &showSQLError($DBI::errstr); unless ($dbh) { &showSQLError($DBI::errstr); } print "\n#"; while($oir=$rqry->fetchrow_hashref) { print "\n- $oir->{'OI_REFERENCE'}"; } print "\n#\n"; $rqry->finish or &showSQLError($DBI::errstr); print "- $oir->{'OI_REFERENCE'}\n"; } sub showSQLError() { print "<SCRIPT> alert('$_[0]');</SCRIPT>"; }

In reply to Perl : DBI and Oracle by aennen

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.