Fwd: concatenate and use as field

Поиск
Список
Период
Сортировка
От Alain Roger
Тема Fwd: concatenate and use as field
Дата
Msg-id 75645bbb0903290441w5f12d718naafb206c9bb8f0b5@mail.gmail.com
обсуждение исходный текст
Ответ на concatenate and use as field  (Alain Roger <raf.news@gmail.com>)
Ответы Fwd: concatenate and use as field  (Alain Roger <raf.news@gmail.com>)
Список pgsql-general
Hi,

i have a character varying variable and i concatenate with some other variable, using the '||' operator.
the result of this concatenation should be the name of a column in my table.

however i don't know how to tell that this new concatenated string is a column name.
how to do it ?
thanks.

in fact i'm trying to do the following thing:

select id, theme_ || $1 from themes;

and based on the parameter my stored procedure has received, it should create something like that:
select id, theme_eng from themes;

if $1 = 'eng'

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

Предыдущее
От: Eugenio Modesti
Дата:
Сообщение: Re: problem with locale :
Следующее
От: Alain Roger
Дата:
Сообщение: Fwd: concatenate and use as field