Re: 9.5.2: "sql" as reserved word?

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Marc Mamin <M(dot)Mamin(at)intershop(dot)de>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: 9.5.2: "sql" as reserved word?
Date: 2016-05-04 14:02:34
Message-ID: CA+TgmoY9kiNvVK=uRfXvnnnN+i0LRmft0gRckEfcKYH9EUCT+g@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, May 4, 2016 at 9:58 AM, Marc Mamin <M(dot)Mamin(at)intershop(dot)de> wrote:
> This query is working in 9.4.x, but not in 9.5.2:
>
> select 'x' sql;
>
> ERROR: syntax error at or near "sql"
> LINE 1: select 'x' sql;
>
> Is this expected or a known issue?
> I could neither find any hint about it in the incompatibility list of the
> 9.5 release notes,
> nor is "sql" listed as reserved keyword.

Sadly, that fails for ANY keyword, not just reserved keywords.
EnterpriseDB has gotten a few customer complaints about this, but it's
not obvious how to fix it.

This commit made SQL a keyword:

commit cac76582053ef8ea07df65fed0757f352da23705
Author: Peter Eisentraut <peter_e(at)gmx(dot)net>
Date: Sun Apr 26 10:33:14 2015 -0400

Add transforms feature

This provides a mechanism for specifying conversions between SQL data
types and procedural languages. As examples, there are transforms
for hstore and ltree for PL/Perl and PL/Python.

reviews by Pavel Stěhule and Andres Freund

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Kevin Grittner 2016-05-04 14:18:58 Re: old_snapshot_threshold's interaction with hash index
Previous Message Amit Kapila 2016-05-04 13:58:49 Re: Is pg_control file crashsafe?