Re: [GENERAL] Determining table change in an event trigger

2016-08-24 Thread Jonathan Rogers
On 08/24/2016 12:58 AM, Alvaro Herrera wrote: > Jonathan Rogers wrote: >> I am trying to use an event trigger to do something when a column >> changes. I can declare an event trigger "ON sql_drop WHEN TAG IN ('ALTER >> TABLE')" to get dropped columns. Howev

[GENERAL] Determining table change in an event trigger

2016-08-23 Thread Jonathan Rogers
e type pg_ddl_command. Am I missing something? Is the documentation lacking? -- Jonathan Rogers Socialserve.com by Emphasys Software jrog...@emphasys-software.com -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] Determining table change in an event trigger

2016-08-23 Thread Jonathan Rogers
e type pg_ddl_command. Am I missing something? Is the documentation lacking? -- Jonathan Rogers Socialserve.com by Emphasys Software jrog...@emphasys-software.com -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] PL/Python prepare example's use of setdefault

2014-11-01 Thread Jonathan Rogers
On 11/01/2014 12:13 PM, Peter Eisentraut wrote: > On 10/15/14 5:58 PM, Jonathan Rogers wrote: >> BTW, I would rewrite the 9.1 example to be shorter while >> behaving the same: >> >> >> CREATE FUNCTION usesavedplan() RETURNS trigger AS $$ >> plan = SD.get(

Re: [GENERAL] PL/Python prepare example's use of setdefault

2014-10-15 Thread Jonathan Rogers
On 10/15/2014 05:51 PM, Adrian Klaver wrote: > On 10/15/2014 02:39 PM, Jonathan Rogers wrote: >> I was just reading the PL/Python docs section "42.7.1 Database Access >> Functions" and saw this example: >> >> CREATE FUNCTION usesavedplan() RETURNS trigger AS

[GENERAL] PL/Python prepare example's use of setdefault

2014-10-15 Thread Jonathan Rogers
I was just reading the PL/Python docs section "42.7.1 Database Access Functions" and saw this example: CREATE FUNCTION usesavedplan() RETURNS trigger AS $$ plan = SD.setdefault("plan", plpy.prepare("SELECT 1")) # rest of function $$ LANGUAGE plpythonu; The above example uses the plpy.prep