Received: from localhost (unknown [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id D2B962E0066 for ; Mon, 3 Mar 2008 13:10:18 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 66167-08 for ; Mon, 3 Mar 2008 13:10:16 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by postgresql.org (Postfix) with ESMTP id E94492E0073 for ; Mon, 3 Mar 2008 13:10:15 -0400 (AST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id m23HAFP4026519; Mon, 3 Mar 2008 12:10:15 -0500 (EST) To: Nuwan Liyanage cc: pgsql-admin@postgresql.org Subject: Re: Delete from base table and not partitions In-reply-to: <657529.64615.qm@web46016.mail.sp1.yahoo.com> References: <657529.64615.qm@web46016.mail.sp1.yahoo.com> Comments: In-reply-to Nuwan Liyanage message dated "Mon, 03 Mar 2008 08:45:45 -0800" Date: Mon, 03 Mar 2008 12:10:14 -0500 Message-ID: <26518.1204564214@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200803/14 X-Sequence-Number: 28497 Nuwan Liyanage writes: > Now I added the trigger rule to base_table and the data for > partition_3 is going to the right place, but I am stuck with some data > in the actual base_table. How could I move that data from the base > table to the partition_3? Something involving SELECT ... FROM ONLY base_table and then DELETE FROM ONLY base_table would do it for you. regards, tom lane