Re: [psycopg] speed concerns with executemany() - Mailing list psycopg

From Christophe Pettus
Subject Re: [psycopg] speed concerns with executemany()
Date
Msg-id 65BA67E3-7F95-4DE4-B4FD-755A253B12A1@thebuild.com
Whole thread Raw
In response to Re: [psycopg] speed concerns with executemany()  (Adrian Klaver <adrian.klaver@aklaver.com>)
Responses Re: [psycopg] speed concerns with executemany()  (Adrian Klaver <adrian.klaver@aklaver.com>)
List psycopg
> On Dec 23, 2016, at 16:58, Adrian Klaver <adrian.klaver@aklaver.com> wrote:
> I understood it did:
>
> http://initd.org/psycopg/docs/usage.html#transactions-control
>
> "It is possible to set the connection in autocommit mode: this way all the commands executed will be immediately
committedand no rollback is possible. A few commands (e.g. CREATE DATABASE, VACUUM...) require to be run outside any
transaction:in order to be able to run these commands from Psycopg, the connection must be in autocommit mode: you can
usethe autocommit property (set_isolation_level() in older versions)." 

My somewhat garbled thought was that each of the component INSERTs in the .executemany would be getting its own
transactionunless the connection was set to autocommit... but I'll admit I haven't tested it. 

--
-- Christophe Pettus
   xof@thebuild.com



psycopg by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: [psycopg] speed concerns with executemany()
Next
From: Adrian Klaver
Date:
Subject: Re: [psycopg] speed concerns with executemany()