Re: Inserting 'large' amounts of data

From: John R Pierce <pierce(at)hogranch(dot)com>
To: Mario Splivalo <mario(dot)splivalo(at)megafon(dot)hr>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Inserting 'large' amounts of data
Date: 2009-08-26 17:17:11
Message-ID: 4A956E17.9020607@hogranch.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Mario Splivalo wrote:
> I have a web application which allows users to upload a lot of phone
> numbers. I need to store those numbers to a database. Usualy, one would
> upload around 70k-100k of records, totaling around 2 MB in size.
>
> ...
> t would one recommend as the best way to insert those data?
>

I believe you can use org.postgresql.copy.CopyIn() ... there are
variants that use a writeToCopy() call to send the data, or a
java.io.InputStream, or a java.io.Reader ...

In response to

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message dmp 2009-08-26 17:28:42 Re: Inserting 'large' amounts of data
Previous Message Mario Splivalo 2009-08-26 16:28:44 Inserting 'large' amounts of data