Re: patch: to_string, to_array functions

From: Itagaki Takahiro <itagaki(dot)takahiro(at)gmail(dot)com>
To: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: patch: to_string, to_array functions
Date: 2010-07-12 07:31:27
Message-ID: AANLkTimTmR75T_uVihRYNRtofyKdLDjIV1OpPGXEKS09@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

2010/7/12 Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>:
> I prefere a new names  - because there are a new behave - with little
> bit better default handling of NULL values. string_to_array and
> array_to_string just ignore NULL values - what isn't correct behave.
> Later we can mark these functions as deprecated and remove it. If I
> use current function, then we have to continue in current behave.

I prefer existing names because your new default behavior can be done
with suitable nullstr values. IMHO, new names will be acceptable only if
they are listed in the SQL-standard or many other databases use the
names. Two similar versions of functions must confuse users.

Also, are there any consensus about "existing functions are not correct" ?
Since string_agg() and your new concat() functions ignores NULLs,
I think it is not so bad for array_to_string() to ignore NULLs.

--
Itagaki Takahiro

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Pavel Stehule 2010-07-12 07:34:40 Re: patch: to_string, to_array functions
Previous Message Pavel Stehule 2010-07-12 07:30:25 Re: patch: preload dictionary new version