> #__DATA___; > # data looks like this, in flat file called dat.prn > #Nov122, aq-xxx , ML, 33 > #Nov122, aq-xxx , ML, 33 > #Nov12 , aq-xxx , DK, 22
If this is literally what your data looks like, including the space between can and the comma, the $can will have a length of 7. (6 chars and a whitespace). The column can only store 6 characters. Strip of any leading and trainling blanks. Maarten. > # Oracle table looks like: > SQL> desc dat; > Name Null? Type > ----------------------------------------- -------- > ------------------------ > PDATE VARCHAR2(12) > CAN VARCHAR2(6) > SITELETTER VARCHAR2(4) > RTIME NUMBER > > > ######## error message ############# > > D:\Perl_resources\PERLSCRIPTS\dbi>perl insert_example.pl > Nov122, aq-xxx , ML, 33 > DBD::Oracle::st execute failed: ORA-01401: inserted value too large for > column (DBD ERROR: OCI > StmtExecute) at insert_example.pl line 26, <DAT> line 1. > Issuing rollback() for database handle being DESTROY'd without explicit > disconnect(), <DAT> li > ne 1. > > >
