Re: CREATE TYPE delimiter?

Поиск
Список
Период
Сортировка
От Command Prompt, Inc.
Тема Re: CREATE TYPE delimiter?
Дата
Msg-id Pine.LNX.4.30.0111031136540.30572-100000@commandprompt.com
обсуждение исходный текст
Ответ на Re: CREATE TYPE delimiter?  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: CREATE TYPE delimiter?  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
On Sat, 3 Nov 2001, Tom Lane wrote:
>So you'd need to have attached the DELIMITER = '|' spec to the
>"zero" datatype to make it effective.  (This seems reasonable to me,
>since it is the element type's formatting that determines what sort
>of delimiter is sensible.)

Ah! Thanks, just tried it, and it works perfectly.

>Now that I look at it, the CREATE TYPE ref page is pretty confusing
>on the whole topic of array types.  I'll see what I can do with it.

Wonderful. While you're in there, you might look at the wording on the
input and output function descriptions; it says that they must take either
one or two arguments of type opaque, but it's not at all clear what the
second argument would be for, in either circumstance.

Also, the DEFAULT clause was a bit curious; it says you can describe "some
specific bit pattern" to mean "data not present"; presumably in place of
NULL? I figured this meant it took a bit string for some kind of internal
handling, but it seems to accept any arbitrary value I give it (integer,
text, though not a b'1001' style bit string!). However, I got some ugly
disconnections from the server after experimenting with this value, and
attempting to SELECT values that would have otherwise been NULL. ;) I
suppose because the output function wasn't set up to handle whatever value
was getting set by this clause?

Thanks again,
Jw.
--
jlx@commandprompt.com
by way of pgsql-general@commandprompt.com


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: CREATE TYPE delimiter?
Следующее
От: "Eric Ridge"
Дата:
Сообщение: Re: SETOF and language 'plpgsql'