Re: psql COPY with JDBC

From: Markus Schaber <schabi(at)logix-tt(dot)com>
To: Christopher Condit <condit(at)sdsc(dot)edu>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: psql COPY with JDBC
Date: 2006-04-04 16:21:06
Message-ID: 44329CF2.6010204@logix-tt.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Hi, Christopher,

Christopher Condit wrote:

> I’ve been trying over at the general postgres list with no luck, so I
> thought I’d try here. I need to bulk load results from a Java
> application on one machine to a postgres db on a remote server. I know
> I can use psql interactively to accomplish this, but I’d like to be able
> to do it programmatically:

Some ideas for "ugly hacks":

- Use a java.lang.ProcessBuilder and pipe into psql

- Use some secure channel (e. G. libjsch or https upload) to copy the
date into a file on the server, and then issue "COPY table FROM file".

HTH,
Markus

--
Markus Schaber | Logical Tracking&Tracing International AG
Dipl. Inf. | Software Development GIS

Fight against software patents in EU! www.ffii.org www.nosoftwarepatents.org

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Markus Schaber 2006-04-04 16:22:16 Re: psql COPY with JDBC
Previous Message Giuseppe Sacco 2006-04-04 15:27:25 Italian translation update and double single quote