Re: Performance of INSERT into temporary tables using psqlODBCdriver - Mailing list pgsql-performance

From padusuma
Subject Re: Performance of INSERT into temporary tables using psqlODBCdriver
Date
Msg-id 1536385261054-0.post@n3.nabble.com
Whole thread Raw
In response to Re: Performance of INSERT into temporary tables using psqlODBC driver  (Tim Cross <theophilusx@gmail.com>)
Responses Re: Performance of INSERT into temporary tables using psqlODBC driver  (Sergei Kornilov <sk@zsrv.org>)
Re: Performance of INSERT into temporary tables using psqlODBC driver  (Tim Cross <theophilusx@gmail.com>)
List pgsql-performance
>We are inserting large numbers (millions) of rows into a postgres
>database from a Javascript application and found using the COPY command
>was much, much faster than doing regular inserts (even with multi-insert
>commit). If you can do this using the driver you are using, that will
>give you the largest performance boost. 

The data to be inserted into temporary tables is obtained from one or more
queries run earlier and the data is available as a vector of strings. If I
need to use COPY FROM command, then the application would need to create a
file with the data to be inserted and the file needs to be readable by the
user running database server process, which may not be always possible
unless the application is running on the same host. I think this approach
may not be feasible for our application.

I have increased the value for /temp_buffers/ server parameter from the
default 8 MB to 128 MB. However, this change did not affect the INSERT time
for temporary tables.




--
Sent from: http://www.postgresql-archive.org/PostgreSQL-performance-f2050081.html


pgsql-performance by date:

Previous
From: Patrick Molgaard
Date:
Subject: Re: Multi-second pauses blocking even trivial activity
Next
From: Sergei Kornilov
Date:
Subject: Re: Performance of INSERT into temporary tables using psqlODBC driver