Re: Add CREATE support to event triggers - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: Add CREATE support to event triggers
Date
Msg-id 20140123185700.GU10723@eldon.alvh.no-ip.org
Whole thread Raw
In response to Re: Add CREATE support to event triggers  (Andres Freund <andres@2ndquadrant.com>)
Responses Re: Add CREATE support to event triggers  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Andres Freund escribió:

> * Why must we not schema qualify system types
>   (c.f. expand_jsonval_typename)? It seems to be perfectly sensible to
>   me to just use pg_catalog there.

So, the reason for doing things this way is to handle cases like
"varchar(10)" being turned into "character varying"; and that name
requires that the typename NOT be schema-qualified, otherwise it fails.
But thinking about this again, I don't see a reason why this can't be
returned simply as pg_catalog.varchar(10); this should work fine on the
receiving end as well, and give the same result.

The other cases I'm worried about are types like bit(1) vs. unadorned
bit vs. double-quoted "bit", and "char", etc.  I'm not sure I'm dealing
with them correctly right now.  So even if by the above paragraph I
could make the is_system thingy go away, I might still need it to cover
this case.

Thanks for the review, I will post an updated version later after fixing
the other issues you mentioned plus adding support for more commands.

-- 
Álvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Warning in new GIN code
Next
From: Stefan Kaltenbrunner
Date:
Subject: Re: [COMMITTERS] pgsql: Compress GIN posting lists, for smaller index size.