Re: [HACKERS] [COMMITTERS] pgsql: Arrange for quote_identifier() and pg_dump to not quote keywords

2007-06-26 Thread Gregory Stark
Tom Lane [EMAIL PROTECTED] writes: For the moment, lie about WITH's status in the table so it will still get quoted --- this is because of the expectation that WITH will become reserved when the SQL recursive-queries patch gets done. Out of curiosity I'm checking what consequences some other

Re: [HACKERS] [COMMITTERS] pgsql: Arrange for quote_identifier() and pg_dump to not quote keywords

2007-06-26 Thread Gregory Stark
Gregory Stark [EMAIL PROTECTED] writes: Tom Lane [EMAIL PROTECTED] writes: For the moment, lie about WITH's status in the table so it will still get quoted --- this is because of the expectation that WITH will become reserved when the SQL recursive-queries patch gets done. Out of curiosity

Re: [HACKERS] [COMMITTERS] pgsql: Arrange for quote_identifier() and pg_dump to not quote keywords

2007-06-26 Thread Gregory Stark
Gregory Stark [EMAIL PROTECTED] writes: Tom Lane [EMAIL PROTECTED] writes: For the moment, lie about WITH's status in the table so it will still get quoted --- this is because of the expectation that WITH will become reserved when the SQL recursive-queries patch gets done. Out of curiosity

Re: [HACKERS] [COMMITTERS] pgsql: Arrange for quote_identifier() and pg_dump to not quote keywords

2007-06-26 Thread Andrew Dunstan
Gregory Stark wrote: I'm thinking it may make sense to lie about all of these in quote_identifier so that someone who upgrades from 8.2 to 8.3 can then upgrade to 8.4. If we add reserved words in one step then there's no way to upgrade except to rename things before dumping. Any comments?

Re: [HACKERS] [COMMITTERS] pgsql: Arrange for quote_identifier() and pg_dump to not quote keywords

2007-06-26 Thread Tom Lane
Andrew Dunstan [EMAIL PROTECTED] writes: I'm confused. Won't pg_dump quote the keywords it knows its postgres version will need quoted? We can't expect it to have knowledge of future requirements for quoting, unless someone really does invent time travel (in which case someone could just go

Re: [HACKERS] [COMMITTERS] pgsql: Arrange for quote_identifier() and pg_dump to not quote keywords

2007-06-26 Thread Gregory Stark
Andrew Dunstan [EMAIL PROTECTED] writes: Gregory Stark wrote: I'm thinking it may make sense to lie about all of these in quote_identifier so that someone who upgrades from 8.2 to 8.3 can then upgrade to 8.4. If we add reserved words in one step then there's no way to upgrade except to

Re: [HACKERS] [COMMITTERS] pgsql: Arrange for quote_identifier() and pg_dump to not quote keywords

2007-06-26 Thread Andrew Dunstan
Gregory Stark wrote: It may still be worth telling one version of Postgres about anticipated keywords prior to a release which adds them so that people who don't follow instructions and try a dump generated with an old pg_dump have a fighting chance. Besides, what's a person to do if they have

Re: [HACKERS] [COMMITTERS] pgsql: Arrange for quote_identifier() and pg_dump to not quote keywords

2007-06-26 Thread Gregory Stark
Tom Lane [EMAIL PROTECTED] writes: Yeah. I'm disinclined to pre-emptively quote things for pie-in-the-sky patches. WITH is already a grammar keyword, so it's not a big deal to tweak things to quote it, but adding a dozen keywords that have zero functionality in the grammar is another thing

Re: [HACKERS] [COMMITTERS] pgsql: Arrange for quote_identifier() and pg_dump to not quote keywords

2007-06-26 Thread Tom Lane
Gregory Stark [EMAIL PROTECTED] writes: Tom Lane [EMAIL PROTECTED] writes: Also, the fact that this particular form of the grammar requires reserving the keywords does not prove that there is no way to have the features without that. I'd want to see us try a little harder first. At least