Re: Cursors in a Loop

2008-01-05 Thread Chris
On Jan 4, 4:32 pm, Carsten Haese <[EMAIL PROTECTED]> wrote: > On Fri, 2008-01-04 at 00:03 -0800, Chris wrote: > > You should bind all variables to save the pool. > > > cursor = connection.cursor() > > cursor.executemany("""insert into as_siebel_hosts_temp > > values (:whole, :

Re: Cursors in a Loop

2008-01-04 Thread Carsten Haese
On Fri, 2008-01-04 at 00:03 -0800, Chris wrote: > You should bind all variables to save the pool. > > cursor = connection.cursor() > cursor.executemany("""insert into as_siebel_hosts_temp > values (:whole, :lot, :of, :bind, :variables) >""" >

Re: Cursors in a Loop

2008-01-04 Thread Chris
On Jan 4, 5:11 am, Carsten Haese <[EMAIL PROTECTED]> wrote: > On Thu, 2008-01-03 at 17:25 -0800, t_rectenwald wrote: > > On Jan 3, 7:47 pm, t_rectenwald <[EMAIL PROTECTED]> wrote: > > > I have a python script that uses the cx_Oracle module. I have a list > > > of values that I iterate through via

Re: Cursors in a Loop

2008-01-03 Thread Carsten Haese
On Thu, 2008-01-03 at 17:25 -0800, t_rectenwald wrote: > On Jan 3, 7:47 pm, t_rectenwald <[EMAIL PROTECTED]> wrote: > > I have a python script that uses the cx_Oracle module. I have a list > > of values that I iterate through via a for loop and then insert into > > the database. This works okay,

Re: Cursors in a Loop

2008-01-03 Thread t_rectenwald
On Jan 3, 7:47 pm, t_rectenwald <[EMAIL PROTECTED]> wrote: > I have a python script that uses the cx_Oracle module.  I have a list > of values that I iterate through via a for loop and then insert into > the database.  This works okay, but I'm not sure whether I can use one > cursor for all inserts

Cursors in a Loop

2008-01-03 Thread t_rectenwald
I have a python script that uses the cx_Oracle module. I have a list of values that I iterate through via a for loop and then insert into the database. This works okay, but I'm not sure whether I can use one cursor for all inserts, and define it outside of the loop, or instantiate and close the c