| From: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
|---|---|
| To: | Frits Jalvingh <jal(at)etc(dot)to> |
| Cc: | Scott Marlowe <scott(dot)marlowe(at)gmail(dot)com>, Kenneth Marshall <ktm(at)rice(dot)edu>, Andreas Kretschmer <andreas(at)a-kretschmer(dot)de>, "pgsql-performance(at)postgresql(dot)org" <pgsql-performance(at)postgresql(dot)org> |
| Subject: | Re: Improving PostgreSQL insert performance |
| Date: | 2017-06-11 02:32:14 |
| Message-ID: | 20170611023214.r2yucev656ojv3pi@alvherre.pgsql |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-performance |
Frits Jalvingh wrote:
> So, I am still very interested in getting normal inserts faster, because
> that will gain speed for all work.. If Oracle can do it, and Postgres is
> able to insert fast with copy- where lies the bottleneck with the insert
> command? There seems to be quite a performance hit with the JDBC driver
> itself (as the stored procedure is a lot faster), so I can look into that.
> But even after that there is quite a gap..
Did you try inserting multiple tuples in one command? Something like
INSERT INTO .. VALUES ('col1', 'col2'), ('col1', 'col2'), ('col1', 'col2')
It's supposed to be faster than single-row inserts, though I don't
know by how much.
--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Joe Conway | 2017-06-11 04:15:18 | Re: Improving PostgreSQL insert performance |
| Previous Message | Frits Jalvingh | 2017-06-10 20:37:48 | Re: Improving PostgreSQL insert performance |