Re:

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема Re:
Дата
Msg-id 162867790807170059y7c3f08bcuc639f149ba457cf4@mail.gmail.com
обсуждение исходный текст
Ответ на  (Paweł Sobański <cfjxcut@wp.pl>)
Список pgsql-general
Hello

2008/7/17 ram subbu <ramgv80@yahoo.com>:
> Hi All,
>     Here i am facing a peculiar scenario. I have a query which always result
> in 3 rows. There are two columns in the query result. I have to make the
> result of 3 rows as a one row
>  select * from tab1;
>
> col1---col2
> ---------------
> 1            5
> 2            38
> 3            50
>
> the result should be
>

select array_to_string(array(select col1 || '-' || col2 from tab1), '/');

regards
Pavel Stehule

> col
> ----
> 1-5/2-38/3-50
>
> Is there any possibilities?
>
>

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

Предыдущее
От: Chris
Дата:
Сообщение: Re: Default fill factor for tables?
Следующее
От: el dorado
Дата:
Сообщение: Standard binaries compilier - how to know?