COPy command question

From: SHARMILA JOTHIRAJAH <sharmi_jo(at)yahoo(dot)com>
To: General postgres mailing list <pgsql-general(at)postgresql(dot)org>
Subject: COPy command question
Date: 2009-02-11 18:22:23
Message-ID: 373693.49047.qm@web110704.mail.gq1.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi,
A question about the Postgresql's COPY command.

This is the syntax of this command from the manual
COPY tablename [ ( column [, ...] ) ]
FROM { 'filename' | STDIN }
[ [ WITH ]
.....
I want to migrate my tables from Oracle to Postgres.
The COPY FROM command can take input from 'file' or 'STDIN'.
Is it possible for the COPY command to take its input from a
java program(which contains the oracle resultset) or any other way?

I know I could get the Oracle rows in a csv format but
Im trying to get it done without any file in between ?

In short is it possible to use this 'COPY' command to migrate my tables'
data from Oracle to Postgresql without using any file in between?

Thanks
Sharmila

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Richard Huxton 2009-02-11 18:32:49 Re: postmaster LISTENing on UDP port 32938
Previous Message Ing. Eris Gomez 2009-02-11 18:18:31 Saber cuando se dispara el trigger (After: insert,update,delete)