Re: column names with - and (

Поиск
Список
Период
Сортировка
От Igor Neyman
Тема Re: column names with - and (
Дата
Msg-id F4C27E77F7A33E4CA98C19A9DC6722A2033FAFC3@EXCHANGE.corp.perceptron.com
обсуждение исходный текст
Ответ на column names with - and (  ("maria s" <psmg01@gmail.com>)
Ответы Re: column names with - and (  ("maria s" <psmg01@gmail.com>)
Список pgsql-sql
Maria,
 
Try "" (double quotes:
 
select x1 as "IL-a", x2 as "IL-a(p30)" from abc
 
should help.
 
Igor

 


From: pgsql-sql-owner@postgresql.org [mailto:pgsql-sql-owner@postgresql.org] On Behalf Of maria s
Sent: Tuesday, July 29, 2008 12:07 PM
To: Osvaldo Rosario Kussama; pgsql-sql@postgresql.org; Pavel Stehule; Ivan Sergio Borgonovo
Subject: [SQL] column names with - and (

Hi All,
When I am fetching the data from a table,
I am giving the column names with - and ( and ) like IL-a, IL-a(p30) etc..

select x1 as IL-a, x2 as IL-a(p30) from abc

But I am getting

ERROR:  syntax error at or near "-" and also t "(" , ")"

Can anyone help me to fix this?

Thank you,
Maria

В списке pgsql-sql по дате отправления:

Предыдущее
От: Ryan Wallace
Дата:
Сообщение: Identifying which column matches a full text search
Следующее
От: Richard Huxton
Дата:
Сообщение: Re: Identifying which column matches a full text search