Re: Re: [HACKERS] Overly strict casting rules? (was: proposal: fix corner use case of variadic fuctions usage)
Chris Travers <chris.travers@gmail.com>
From: Chris Travers <chris.travers@gmail.com>
To: Craig Ringer <craig@2ndquadrant.com>
Cc: Robert Haas <robertmhaas@gmail.com>, "pgsql-general@postgresql.org" <pgsql-general@postgresql.org>
Date: 2013-01-21T03:55:01Z
Lists: pgsql-hackers, pgsql-general
On Sun, Jan 20, 2013 at 7:15 PM, Craig Ringer <craig@2ndquadrant.com> wrote: > > FWIW, I find PostgreSQL's type casting rules excessively strict and very > painful, especially when working via query generation layers and ORMs > with pseudo-text data types like "xml" and "json". I'd rather work with > direct SQL, but that's not always an option. > I want to second this specifically with regard to XML and JSON. I understand the concern about implicit casts to text, but what about bundling with a built-in domain that pseudo-text types can be implicitly cast to? Something like a generaltext type, where casts from other pseudo-text types are implicitly cast? hmmm might be worth playing around with this in extension format..... Best Wishes, Chris Travers