[DB-SIG] RE: Re: [DB-SIG] oracledb and LONG

Anthony Baxter Anthony Baxter <arb@connect.com.au>
Sat, 19 Sep 1998 00:59:49 +1000

>>> "Jekabs Andrusaitis" wrote
> > sql = 'INSERT INTO TABLE_1 (COL_1) VALUES (:1)'
> > cursor.execute(sql, (longVal, ))
> I believe it is always a good idea to use bind variables. That way you dont
> have to worry about contents of string you want to insert.

It's also considerably more efficient - the database doesn't have
to re-parse the SQL each time. Certainly in the case of Oracle, it
caches the parsed SQL automatically.

Anthony, trying to work out how to build a system that can handle
500 row inserts/second (sustained, over 24/7 :(