Nope didn't wk but thanks.  I suspect clob/blobs are db independent so must
be an oracle example to guarantee success.  

Any oracle examples out there when brings a clob string back
from Oracle to a web page?

>
>I do not use Oracle, so it's just a guess, but this sounds as if it 
>could be solved by setting LongTruncOk => 1 and adjusting LongReadLen 
>to some reasonable value.
>
>Bodo 
>
>> See attached code:
>> 
>> Any pointers to DBI examples for oracle to do this?
>> No example clob storage/retreival in perl/dbi book.
>> 
>> clob column stores/retrieves ok using sqlplus.  
>> 
>> Attached DBI script connects & dies on "execute" 
>> statement if column is clob.  Works
>> when clob field is not addressed.
>> ------------------------------------------------
>>  #!d:/perl/bin/perl.exe -w
>>   print "Content-type: text/html\r\n\r\n";
>>  use CGI qw/:standard/;
>>  use DBI;
>>  open (STDERR, "error_file.txt");
>>  $g_id = param('g_id');
>> 
>>  $n_edit = "n_edit.pl";
>>  $ff = "";
>>  %attr =
>>   PrintError => 0,
>>   RaiseError => 1
>>  );
>>  my $dbh =
>>  DBI->connect('DBI:Oracle:ORACLEX.X','log','pas',\%attr) or die
>>  "Couldn't connect to database: " . DBI->errstr;
>> 
>>  $query = "select n from X"; # <-- n = clob field...
>>                                    in table X
>>  $sth1 = $dbh->prepare($query);
>>  $sth1->execute;  # <-- code stops processing here...
>>  $ko_id = 0;
>>  while ( ($note) = $sth1->fetchrow() )
>> 
>>  print "<TR><td>   
>>  Edit </td><td>$ff
>>  $title</td><td>$note</td></TR>";
>> 
>>  print "</table>",hr;
>>  print "<table border = 0>";
>>  print "<TR><td>  
>>  Edit </td><td>$ff
>>  $title</td><td>$note</td></TR>";
>> 
>>  print "</table>";
>>  $sth->finish;
>>  $dbh->disconnect
>>       or die "Disconnect failed: $dbh->errstr()";
>>  print "";
>>  exit;
>> --------------------------------------------------------
>> 
>> 
>
>

Reply via email to