Re: Implicit casts to text

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Implicit casts to text
Date: 2007-04-03 01:25:19
Message-ID: 200704030125.l331PJH11781@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Added to TODO:

* Allow all data types to cast to and from TEXT

http://archives.postgresql.org/pgsql-hackers/2007-04/msg00017.php

---------------------------------------------------------------------------

Tom Lane wrote:
> Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> > The attached patch changes all implicit casts to text to assignment and
> > cleans up the associated regression test damage. This change has been
> > discussed for the longest time; I propose that we bite the bullet and
> > do it now.
>
> [ I'm assuming this isn't an April-fool item, otherwise never mind ]
>
> The scheme that was in the back of my mind was to do this at the same
> time as providing a general facility for casting *every* type to and
> from text, by means of their I/O functions if no specialized cast is
> provided in pg_cast. This would improve functionality, thus providing
> a salve to the annoyance of users whose code the restriction breaks:
> we can certainly argue that it wouldn't do for all those automatically
> created casts to be implicit. At the same time it'd let us eliminate
> redundant text-to/from-foo code that's currently in place for some but
> not all datatypes.
>
> If we do only the restrictive part of this, it's a harder sale.
>
> So, +1 on the concept, but I think we want a larger patch, and it's
> probably too late for that for 8.3.
>
> regards, tom lane
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: don't forget to increase your free space map settings

--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://www.enterprisedb.com

+ If your life is a hard drive, Christ can be your backup. +

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Joshua D. Drake 2007-04-03 01:59:29 Re: Feature thought: idle in transaction timeout
Previous Message Bruce Momjian 2007-04-03 01:23:17 Re: Logging checkpoints and other slowdown causes