X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id D1428D1B33D for ; Fri, 2 Jul 2004 08:37:32 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 75662-09 for ; Fri, 2 Jul 2004 11:37:31 +0000 (GMT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by svr1.postgresql.org (Postfix) with ESMTP id 5969CD1B18C for ; Fri, 2 Jul 2004 08:37:27 -0300 (ADT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by news.hub.org (8.12.9/8.12.9) with ESMTP id i62BbRZ3031928 for ; Fri, 2 Jul 2004 11:37:27 GMT (envelope-from news@news.hub.org) Received: (from news@localhost) by news.hub.org (8.12.9/8.12.9/Submit) id i62BADck027102 for pgsql-sql@postgresql.org; Fri, 2 Jul 2004 11:10:13 GMT From: reina_ga@hotmail.com (Tony Reina) X-Newsgroups: comp.databases.postgresql.sql Subject: Re: best method to copy data across databases Date: 2 Jul 2004 04:10:15 -0700 Organization: http://groups.google.com Lines: 28 Message-ID: <272e4be7.0407020310.18785557@posting.google.com> References: <46a31c4d.0407011942.37839bb0@posting.google.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Complaints-To: groups-abuse@google.com To: pgsql-sql@postgresql.org X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200407/14 X-Sequence-Number: 18266 ctrl@altonsys.com (ctrl) wrote in message news:<46a31c4d.0407011942.37839bb0@posting.google.com>... > I need to copy data that I have on a table in one Postgres database > into another table, on a different database. The destination table is > not identical with the source table so I need to do some mapping > between the 2 tables. > What would be the best (and quickest) way to transfer the data? (there > are over 500k rows) > > thanks! If the 2 tables have different arrangements, then I'm not sure if there is a quick way. The safest way is probably to do a pg_dump --attribute-inserts.