Environment:

SunOS 5.5.1 Generic_103640-36 sun4u sparc SUNW,Ultra-2
Oracle Enterprise Server 8.0.5 (on remote SunOS)
DBI 1.20 (all tests OK)
DBD::Oracle 1.12 (all tests OK)
Netscape 4.76

Hello,

I have a table:
=====================================================
SQL> desc pub;
 Name                            Null?    Type
 ------------------------------- -------- ----
 ID_PUB                          NOT NULL NUMBER(5)
 TYP_PUB                                  VARCHAR2(3)
 ROK_PUB                                  DATE
 BIN_PUB                                  BLOB
 NRD_PUB                                  VARCHAR2(20)
 DATA_PUB                                 DATE
 
SQL>
=====================================================

and a CGI script 'pub.cgi' that reads data from a HTML form 
and puts it remotely to the table 'pub'. I don't have a field 
that correspond to 'bin_pub' (BLOB) column - it is modified 
from another program with no problems. 

When I submit the form, everything is OK. But when I press 'Back' button,
I have my form already filled (browser cache). I make a small change in 
a text field and submit it again. Then I get an error:

pub.cgi: DBD::Oracle::st execute failed: 
ORA-01801: date format is too long for internal buffer 
(DBD ERROR: OCIStmtExecute)

When I back from error page again and submit for the third time, my
record is modified correctly.

I tried to find out something from dbi-list and after reading a few letters
with ORA-01801 problem I decided to set:

$dbh->{LongReadLen} = 2000000;
$dbh->{LongTruncOk} = 1;

but it didn't make any change.

Conclusions: when I submit a form for the first time I have no problems,
but when I back a page and submit it again, I get ORA-01801. It looks
like it is the problem of a browser but Netscape 4.75 and IE 5.5 on Windows 
had the same results.

How can I avoid it? Does anyone faced with such a problem? 

I would appreciate any help. Thank you in advance,
-- 
Wojciech Pietron    [EMAIL PROTECTED]
National Institute of Telecommunications OI
Szachowa 1, 04-894 Warsaw, POLAND
tel: +48 22 5128126

Reply via email to