From: Bruce Momjian on 14 Jun 2010 06:57 Robert Haas wrote: > In response to a complaint from Hartmut Goebel: > > http://archives.postgresql.org/pgsql-bugs/2010-06/msg00018.php > > And per a design proposed by Tom Lane: > > http://archives.postgresql.org/pgsql-bugs/2010-06/msg00211.php > > PFA a patch to implement $SUBJECT. One interesting aspect of this > patch is that types like "integer" and "double precision" don't get > quoted in the output, whereas types like "text" do. But it turns out > that types like "integer" and "double precision" don't *work* if > they're quoted, so this is not a bad thing. It might possibly be > judged to require documentation somewhere, however. Uh, I thought this was about quoting the identifiers. I am confused about why "integer" is an issue in this case. Can you show an example? -- Bruce Momjian <bruce(a)momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + None of us is going to be here forever. + -- Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
From: Robert Haas on 14 Jun 2010 07:15 On Mon, Jun 14, 2010 at 6:57 AM, Bruce Momjian <bruce(a)momjian.us> wrote: > Robert Haas wrote: >> In response to a complaint from Hartmut Goebel: >> >> http://archives.postgresql.org/pgsql-bugs/2010-06/msg00018.php >> >> And per a design proposed by Tom Lane: >> >> http://archives.postgresql.org/pgsql-bugs/2010-06/msg00211.php >> >> PFA a patch to implement $SUBJECT. �One interesting aspect of this >> patch is that types like "integer" and "double precision" don't get >> quoted in the output, whereas types like "text" do. �But it turns out >> that types like "integer" and "double precision" don't *work* if >> they're quoted, so this is not a bad thing. �It might possibly be >> judged to require documentation somewhere, however. > > Uh, I thought this was about quoting the identifiers. �I am confused > about why "integer" is an issue in this case. �Can you show an example? Sure. rhaas=# create table bruce (demonstration "integer"); ERROR: type "integer" does not exist LINE 1: create table bruce (demonstration "integer"); ^ rhaas=# create table bruce (demonstration integer); CREATE TABLE See gram.y, around line 8341. Note that if you try the same example with "text" instead of "integer", both variants work. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise Postgres Company -- Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
From: Tom Lane on 14 Jun 2010 10:05 Robert Haas <robertmhaas(a)gmail.com> writes: > On Mon, Jun 14, 2010 at 6:57 AM, Bruce Momjian <bruce(a)momjian.us> wrote: >> Uh, I thought this was about quoting the identifiers. �I am confused >> about why "integer" is an issue in this case. �Can you show an example? > Sure. INTEGER is actually a keyword in this context, not an identifier. (Remember the actual name of the type is int4, not integer.) regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
|
Pages: 1 Prev: [HACKERS] pg_archive_bypass Next: [v9.1] Add security hook on initialization of instance |