Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TwFzK-0008M0-LI for pgsql-hackers@arkaria.postgresql.org; Fri, 18 Jan 2013 17:44:23 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.72) (envelope-from ) id 1TwFzJ-0006hQ-8J for pgsql-hackers@arkaria.postgresql.org; Fri, 18 Jan 2013 17:44:21 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TwFzI-0006hL-6j for pgsql-hackers@postgresql.org; Fri, 18 Jan 2013 17:44:20 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TwFzG-0005kZ-6x for pgsql-hackers@postgresql.org; Fri, 18 Jan 2013 17:44:19 +0000 Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.5/8.14.5) with ESMTP id r0IHiE7r010184; Fri, 18 Jan 2013 12:44:14 -0500 (EST) From: Tom Lane To: Andres Freund cc: Robert Haas , Dimitri Fontaine , Simon Riggs , Alvaro Herrera , PostgreSQL Hackers Subject: Re: Event Triggers: adding information In-reply-to: <20130118170857.GK29501@alap2.anarazel.de> References: <16675.1358454278@sss.pgh.pa.us> <18941.1358462151@sss.pgh.pa.us> <20130118013334.GE3074@awork2.anarazel.de> <20130118140721.GA29501@alap2.anarazel.de> <20130118154732.GE29501@alap2.anarazel.de> <20130118170857.GK29501@alap2.anarazel.de> Comments: In-reply-to Andres Freund message dated "Fri, 18 Jan 2013 18:08:57 +0100" Date: Fri, 18 Jan 2013 12:44:13 -0500 Message-ID: <10183.1358531053@sss.pgh.pa.us> X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org Andres Freund writes: > On 2013-01-18 11:42:47 -0500, Robert Haas wrote: >> I'm having trouble following this. Can you restate? I wasn't sure >> what you meant by libpqdump. I assumed you were speaking of a >> parsetree->DDL or catalog->DDL facility. > Yea, that wasn't really clear, sorry for that. > What I was trying to say that I think doing parstree->text conversion > out of tree is noticeably more complex and essentially places a higher > maintenance burden on the project because Ah. That's not pg_dump's job though, so you're choosing a bad name for it. What I think you are really talking about is extending the deparsing logic in ruleutils.c to cover utility statements. Which is not a bad plan in principle; we've just never needed it before. It would be quite a lot of new code though. An issue that would have to be thought about is that there are assorted scenarios where we generate "parse trees" that contain options that cannot be generated from SQL, so there's no way to reverse-list them into working SQL. But often those hidden options are essential to know what the statement will really do, so I'm not sure ignoring them will be a workable answer for replication purposes. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers