X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (neptune.hub.org [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id A3378D1DB82 for ; Tue, 13 Jan 2004 16:24:23 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 71693-10 for ; Tue, 13 Jan 2004 12:23:52 -0400 (AST) Received: from noao.edu (noao.edu [140.252.1.54]) by svr1.postgresql.org (Postfix) with ESMTP id 32B1BD1B469 for ; Tue, 13 Jan 2004 12:23:51 -0400 (AST) Received: from weaver.tuc.noao.edu ([140.252.38.8] verified) by noao.edu (CommuniGate Pro SMTP 4.1.8) with ESMTP-TLS id 10208762; Tue, 13 Jan 2004 09:23:49 -0700 Received: from weaver.tuc.noao.edu (localhost.localdomain [127.0.0.1]) by weaver.tuc.noao.edu (8.12.8/8.12.5) with ESMTP id i0DGNnNn011902; Tue, 13 Jan 2004 09:23:49 -0700 Received: (from swampler@localhost) by weaver.tuc.noao.edu (8.12.8/8.12.8/Submit) id i0DGNnPV011900; Tue, 13 Jan 2004 09:23:49 -0700 X-Authentication-Warning: weaver.tuc.noao.edu: swampler set sender to swampler@noao.edu using -f Subject: Copying rows between tables? From: Steve Wampler Reply-To: swampler@noao.edu To: Postgres-SQL Content-Type: text/plain Content-Transfer-Encoding: 7bit Organization: National Solar Observatory Message-Id: <1074011028.18994.18.camel@weaver.tuc.noao.edu> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.5 Date: Tue, 13 Jan 2004 09:23:48 -0700 X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200401/110 X-Sequence-Number: 16503 I know I can select from one table into a new table, but is there a way to select from one table into an existing table (aside from copying everything to a file, editing the file and then copying from that file)? Without destroying existing entries, of course... I have an application where old records are archived into 'archive' tables. Occasionally there is a need to copy some of these old records into the 'active' table. Thanks for any pointers! Steve -- Steve Wampler -- swampler@noao.edu The gods that smiled on your birth are now laughing out loud.