Re: [HACKERS] get_cast_func syscache utility function

2014-11-05 Thread Andrew Dunstan
On 11/05/2014 10:10 AM, Tom Lane wrote: Andrew Dunstan writes: On 11/04/2014 01:45 PM, Tom Lane wrote: In short, I'd rather see this addressed through functions with slightly higher-level APIs that are capable of covering more cases. In most cases it'd be best if callers were using find_coer

Re: [HACKERS] get_cast_func syscache utility function

2014-11-05 Thread Tom Lane
Andrew Dunstan writes: > On 11/04/2014 01:45 PM, Tom Lane wrote: >> In short, I'd rather see this addressed through functions with slightly >> higher-level APIs that are capable of covering more cases. In most cases >> it'd be best if callers were using find_coercion_pathway() rather than >> taki

Re: [HACKERS] get_cast_func syscache utility function

2014-11-05 Thread Andrew Dunstan
On 11/04/2014 01:45 PM, Tom Lane wrote: Andrew Dunstan writes: here's a patch for a utility function to look up the cast function for a from/to pair of types, as recently suggested by Alvaro. Although it only contains one use (in json.c), the upcoming jsonb generators would also use it twice.

Re: [HACKERS] get_cast_func syscache utility function

2014-11-04 Thread Tom Lane
Andrew Dunstan writes: >> here's a patch for a utility function to look up the cast function for >> a from/to pair of types, as recently suggested by Alvaro. Although it >> only contains one use (in json.c), the upcoming jsonb generators would >> also use it twice. I'd like to get this committe

Re: [HACKERS] get_cast_func syscache utility function

2014-11-04 Thread Andrew Dunstan
On 11/04/2014 12:57 PM, Andrew Dunstan wrote: here's a patch for a utility function to look up the cast function for a from/to pair of types, as recently suggested by Alvaro. Although it only contains one use (in json.c), the upcoming jsonb generators would also use it twice. I'd like to get

Re: [HACKERS] get_cast_func syscache utility function

2014-11-04 Thread Pavel Stehule
missing patch Regards Pavel 2014-11-04 18:57 GMT+01:00 Andrew Dunstan : > > here's a patch for a utility function to look up the cast function for a > from/to pair of types, as recently suggested by Alvaro. Although it only > contains one use (in json.c), the upcoming jsonb generators would als