A long time ago, in a galaxy far, far away, "azaz" <oi*******@azijza.com> wrote:
Hello all !
I'm a PostgreSQL newbie.
I'd like to know how to copy a table called TABLE1 and located in DATABASE1
as a TABLE2 which will be located in DATABASE2.
I have'nt found anything concerning table copies between databases with SQL.
Thanx for your help.
Jérôme
There is a "db_link" system that can do some crosslinks between
databases, but this isn't something you can accomplish directly in SQL...
Perhaps you might try:
% pg_dump -c -t TABLE1 DATABASE1 | psql DATABASE2
--
(format nil "~S@~S" "cbbrowne" "ntlug.org")
http://www.ntlug.org/~cbbrowne/rdbms.html
"I've run DOOM more in the last few days than I have the last few
months. I just love debugging ;-)" -- Linus Torvalds