Re:

Поиск
Список
Период
Сортировка
От Alvaro Herrera Munoz
Тема Re:
Дата
Msg-id 20030612152021.GE7797@dcc.uchile.cl
обсуждение исходный текст
Ответ на ...  (<mogas@aveiro-digital.net>)
Список pgsql-general
On Thu, Jun 12, 2003 at 10:16:13AM +0100, mogas@aveiro-digital.net wrote:

> I have a varchar variable that have inside something like 8:50. I need to
> broke it and cast each part into two integer variables (x=8 and y=50).

> If someone know how to do this please tell me to this mail if possible.

I think you can do something like
SELECT split_part('8:50', ':', 1), split_part('8:50', ':', 2);

--
Alvaro Herrera (<alvherre[@]dcc.uchile.cl>)
"La realidad se compone de muchos sue�os, todos ellos diferentes,
pero en cierto aspecto, parecidos..." (Yo, hablando de sue�os er�ticos)

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

Предыдущее
От: Edmund Dengler
Дата:
Сообщение: Re: Performance of query (fwd)
Следующее
От: Stephan Szabo
Дата:
Сообщение: Re: full featured alter table?