Re: User defined I/O conversion casts

From: Teodor Sigaev <teodor(at)sigaev(dot)ru>
To: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: User defined I/O conversion casts
Date: 2008-08-29 11:50:44
Message-ID: 48B7E294.4030603@sigaev.ru
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


> Since 8.3, the system provides automatic I/O conversion casts between
> the built-in string types and other types, but there's currently no way
> for a user to declare additional casts using the I/O functions. You can
> always create a simple SQL function to do that, but it seems like we
> should provide a direct interface for that. I propose the syntax:
>
> CREATE CAST (<source> AS <target>) WITH INOUT [AS IMPLICIT | AS ASSIGNMENT]

> Anyone else think this is a good idea? Thoughts on the implementation?

Agree, that task causes too often for me. Although using separate boolean column
looks more preferable than special value for OID.

--
Teodor Sigaev E-mail: teodor(at)sigaev(dot)ru
WWW: http://www.sigaev.ru/

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2008-08-29 13:02:33 pgsql: Remove all traces that suggest that a non-Bison yacc might be
Previous Message Heikki Linnakangas 2008-08-29 10:59:01 User defined I/O conversion casts