Re: Selecting strict, immutable text for a composite type.

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Selecting strict, immutable text for a composite type.
Дата
Msg-id 20099.1525967568@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Selecting strict, immutable text for a composite type.  (Steven Lembark <lembark@wrkhors.com>)
Список pgsql-general
Steven Lembark <lembark@wrkhors.com> writes:
> Q: What is the syntax for a strict, immutable function in 
>    SQL that returns text suitable for use with either 
>    creating a "select *" view or a GIST index?

Your example works just fine for me ...

regression=# select lat_lng_text('(42,54.5)');
 lat_lng_text 
--------------
 42-54.5
(1 row)

Maybe you should show a more concrete example of what's not working.

Side comment: I think you need to rethink that text representation,
because it'll be at best ugly with a negative longitude.  Is there a
reason not to just use the default record representation (with parens
and a comma)?

            regards, tom lane


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

Предыдущее
От: Francisco Olarte
Дата:
Сообщение: Re: Enhancement to psql command, feedback.
Следующее
От: Ben Hood
Дата:
Сообщение: Re: Domain based on TIMEZONE WITH TIME ZONE