Re: trigger/for key help

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Greg Stark <gsstark(at)mit(dot)edu>
Cc: Bret Hughes <bhughes(at)elevating(dot)com>, Stephan Szabo <sszabo(at)megazone(dot)bigpanda(dot)com>, postgresql sql list <pgsql-sql(at)postgresql(dot)org>
Subject: Re: trigger/for key help
Date: 2004-04-13 18:35:24
Message-ID: 25084.1081881324@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Greg Stark <gsstark(at)mit(dot)edu> writes:
>>> Is there a reason postgres goes out of its way to pick names that
>>> will be harder to work with than necessary?

> I don't see an unseverable link between "user name space" and "identifiers
> that don't need to be quoted". Mixed case names for instance seem like
> perfectly good user name space identifiers.

Sure, but they still have to be quoted. The issue here was specifically
about whether the identifiers have to be quoted or not.

> Postgres could just as easily say "the system reserves all identifiers
> starting with $" and still not require quoting $.

At this point identifiers starting with $ are a completely lost cause ;-).
We have the parameter notation $n conflicting if the next character is a
digit, and the dollar-quote mechanism conflicting with any other second
character, and both of these are significantly more useful than the
ability to have unquoted IDs starting with $ would be. So that's a dead
end. I think if we wanted to change the default assignment of
constraint names we'd just go with ordinary identifiers that we hope
won't conflict with names the user picks.

regards, tom lane

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Dennis 2004-04-13 22:41:52 function returning array
Previous Message Jeff Boes 2004-04-13 18:34:38 Re: SQL challenge--top 10 for each key value?