Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TyYYi-0003qu-0w for pgsql-hackers@arkaria.postgresql.org; Fri, 25 Jan 2013 01:58:24 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.72) (envelope-from ) id 1TyYYh-0008Iu-I9 for pgsql-hackers@arkaria.postgresql.org; Fri, 25 Jan 2013 01:58:23 +0000 Received: from makus.postgresql.org ([98.129.198.125]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TyYYf-0008Ip-UV for pgsql-hackers@postgresql.org; Fri, 25 Jan 2013 01:58:22 +0000 Received: from outbound.afilias.info ([66.199.183.4]) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TyYYd-0007wK-Rk for pgsql-hackers@postgresql.org; Fri, 25 Jan 2013 01:58:21 +0000 Received: from ms5.on1.afilias-ops.info ([10.109.8.9] helo=smtp.afilias.info) by outbound.afilias.info with esmtp (Exim 4.69) (envelope-from ) id 1TyYYc-00019i-67 for pgsql-hackers@postgresql.org; Fri, 25 Jan 2013 01:58:18 +0000 Received: from mail-ob0-f197.google.com ([209.85.214.197]) by smtp.afilias.info with esmtps (TLSv1:RC4-SHA:128) (Exim 4.72) (envelope-from ) id 1TyYYc-00066g-5h for pgsql-hackers@postgresql.org; Fri, 25 Jan 2013 01:58:18 +0000 Received: by mail-ob0-f197.google.com with SMTP id ta14so12055816obb.4 for ; Thu, 24 Jan 2013 17:58:13 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:x-received:message-id:date:from:user-agent:mime-version :to:cc:subject:references:in-reply-to:content-type :content-transfer-encoding:x-gm-message-state; bh=WzzPo5lr1wBT6iQFdM+ra79JZ5VAV/yVxj4J/VokBdg=; b=HJqk1fytRwNe39gMqIzhwnzmg7BEJLRi1E7qXiG1aGml3iePvk1mjMhyTLlJBgjyMf DeH4oKlxoc3ko2Ne8DkS9Y2bO7LLatkDceTNMs9POm94R886DgqQ2VgVwndip9MkE9WR qECUmfwieDHW+r5SNQKKb40UAebH/Tgw3sIl7yyjqG4K+MHSudoq6u2shRqHmSRBtI/m hlkXh9B05HFI/hdKOzHpzHnqnpOvM8yIWmIkI3bpcjv0G/GkPnBcjVYqBYV1+pX4F7kp ZgWKs/xQxvuICVhsQ6KL0uyhuhKIHCrTbNthtmThwZ8FKajt6AbN1d1Otc0xg852dLjU fJDQ== X-Received: by 10.50.170.36 with SMTP id aj4mr3044770igc.92.1359079092948; Thu, 24 Jan 2013 17:58:12 -0800 (PST) X-Received: by 10.50.170.36 with SMTP id aj4mr3044766igc.92.1359079092863; Thu, 24 Jan 2013 17:58:12 -0800 (PST) Received: from [192.168.1.5] ([64.231.26.170]) by mx.google.com with ESMTPS id iw5sm2676777igc.5.2013.01.24.17.58.11 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 24 Jan 2013 17:58:12 -0800 (PST) Message-ID: <5101E6B2.5010602@ca.afilias.info> Date: Thu, 24 Jan 2013 20:58:10 -0500 From: Steve Singer User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0 MIME-Version: 1.0 To: Dimitri Fontaine CC: Robert Haas , Andres Freund , Alvaro Herrera , PostgreSQL Hackers Subject: Re: Event Triggers: adding information References: <20130104205251.GB9191@alvh.no-ip.org> <20130109165829.GB4490@alvh.no-ip.org> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Gm-Message-State: ALoCoQlvHVzxJQAHWX/8hA+ead5yHYey8SX4VdzdA9a4sXgCfsnJSrMuH/6MALo6r4VyXAay1m2WUEDH/b5Uyo/e67ydZdIV3rnf7li1jUHq70c6DLtxQRFxm/sthMCigT2EOrG05rgISprmUTZ6/Vm3DY8xhgPcU1SUs4UaRZGNb6q8WkV2Sek= 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 On 13-01-24 05:43 AM, Dimitri Fontaine wrote: > Robert Haas writes: >> On Mon, Jan 21, 2013 at 12:27 PM, Dimitri Fontaine >> wrote: >>> - Context exposing and filtering >> >> I'm not feeling very sanguine about any of this. I feel strongly that >> we should try to do something that's more principled than just >> throwing random junk into ProcessUtility. > > The goal is to allow for advanced users of that feature to get at the > sequence, constraints and index names that have been picked > automatically by PostgreSQL when doing some CREATE TABLE statement that > involves them: > > CREATE TABLE foo (id serial PRIMARY KEY, f1 text); > > Andres and Steve, as you're the next ones to benefit directly from that > whole feature and at different levels, do you have a strong opinion on > whether you really need that to operate at the logical level? > I haven't been following this thread very closely and I'm not exactly sure what your asking. If the question is what a replication system would need to replicate DDL commands, then I need a method of translating whatever the DDL trigger is passed into either the 'CREATE TABLE public.foo(id serial primary key, f1 text)' OR some set of equivalent commands that will allow me to create the same objects on the replica. I don't have any brilliant insight on how I would go about during it. Honestly I haven't spent a lot of time thinking about it in the past 8 months. If your asking what I would need for a trigger to automatically add a new table to replication then I think I would only need to know (or be able to obtain) the fully qualified name of the table and then in another trigger call be given the name of the fully qualified name of the sequence. The triggers would need to be able to do DML to configuration tables. I don't need to know that a table and sequence are connected if all I want to do is replicate them. -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers