Search Postgresql Archives

Re: Mandatory AS keyword in SELECT statements

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



vincent.moreau@xxxxxxxxxxxxxxxx wrote:
> Hi,
> 
> We are currently trying to migrate an Oracle database to PostgreSQL.
> Unfortunately, the Java application that access the database does not 
> use the AS keyword to alias column names in select statements.
> 
> Thus, the following statement "SELECT col1 alias1 FROM any_table" fails.
> 
> AFAIK, AS is optional according to SQL Standard.
> Is there a way to workaround this behaviour, as it will be not possible 
> for us to modify the application ?
> Is there a plan to support this in future PostgreSQL releases ?
> 
> I apologize in advance if this question has already been submited, I was 
> not able to find some threads discussing this point.

Unfortunately, this is on our TODO list as something we are not planning
to do:
	
	* Allow AS in "SELECT col AS label" to be optional (not wanted)
	
	  Because we support postfix operators, it isn't possible to make AS
	  optional and continue to use bison.

-- 
  Bruce Momjian  <bruce@xxxxxxxxxx>        http://momjian.us
  EnterpriseDB                             http://postgres.enterprisedb.com

  + If your life is a hard drive, Christ can be your backup. +

---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
       choose an index scan if your joining column's datatypes do not
       match

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux