Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> DBI delete, long data type insert into Oracle DB table

DBI delete, long data type insert into Oracle DB table

From: <weiq3777_at_my-deja.com>
Date: Sat, 02 Oct 1999 20:30:10 GMT
Message-ID: <7t5q0j$6u8$1@nnrp1.deja.com>


Hi, All

I have some difficult to use DBI, perl to delete a record in oracle database.

for example, $SQL = "delete from testTable where id = 1";

             &RunSQLStatement($SQL);

          sub RunSQLStatement($)
          {
             local ($sth) = $dbh-> prepare($_[0]);
             if ( !defined $sth )  {
                  die "Cannot prepare statement: $DBI::errstr\n";
             }
             $sth->execute;
           }

I can use the above RunSQLStatement function to insert, update tables, except for long database type. However, I can not call the above RunSQLStatement function to delete a record.

I would be very grateful if anyone cold help me,

1....how to modify the above function to let me execute a delete SQL

     statement
2....how to modofy the above function to let me insert data into a

     table which has long data type and the long data type field has
     more than 2000 chars.

Thanks and have a nice weekend.

Wei

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Sat Oct 02 1999 - 15:30:10 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US