remove convert using

Поиск
Список
Период
Сортировка
Искать

remove convert using

От:
Andrew Dunstan <andrew@dunslane.net>
Дата:
Вложения:

The attached patch removes "convert ... using ..." as recently discussed 
on -hackers. Most of the patch is regression test changes.

If there's no objection I'll apply it in a day or two.

cheers

andrew

Re: remove convert using

От:
Tom Lane <tgl@sss.pgh.pa.us>
Дата:
Andrew Dunstan  writes:
> The attached patch removes "convert ... using ..." as recently discussed 
> on -hackers. Most of the patch is regression test changes.

You should be able to remove CONVERT as a grammar keyword altogether
-- the remaining production for CONVERT as a function name seems dead
weight now (not to mention that it prevents having user-defined
functions named CONVERT).

Other than that omission it looks sane to me.

			regards, tom lane

Re: remove convert using

От:
Andrew Dunstan <andrew@dunslane.net>
Дата:


Tom Lane wrote:
> Andrew Dunstan  writes:
>   
>> The attached patch removes "convert ... using ..." as recently discussed 
>> on -hackers. Most of the patch is regression test changes.
>>     
>
> You should be able to remove CONVERT as a grammar keyword altogether
> -- the remaining production for CONVERT as a function name seems dead
> weight now (not to mention that it prevents having user-defined
> functions named CONVERT).
>
>
>   

I wonderted a bit about that. I thought it might be better to leave it 
in case we wanted to put back "convert using" when we have better 
support for multiple encodings (and maybe when we understand better what 
it is actually supposed to do).

But I have no strong opinions on the subject.

cheers

anmdrew

Re: remove convert using

От:
Tom Lane <tgl@sss.pgh.pa.us>
Дата:
Andrew Dunstan  writes:
> Tom Lane wrote:
>> You should be able to remove CONVERT as a grammar keyword altogether
>> -- the remaining production for CONVERT as a function name seems dead
>> weight now (not to mention that it prevents having user-defined
>> functions named CONVERT).

> I wonderted a bit about that. I thought it might be better to leave it 
> in case we wanted to put back "convert using" when we have better 
> support for multiple encodings (and maybe when we understand better what 
> it is actually supposed to do).

Well, we could always put it back when we need it --- in the meantime,
every extra keyword is some fractional drag on parsing performance.

In any case I think the remaining production is probably wrong because
it constrains the function to be in pg_catalog schema, when there is
no grammatical evidence that it should be special.

			regards, tom lane

Re: remove convert using

От:
Andrew Dunstan <andrew@dunslane.net>
Дата:


Tom Lane wrote:
> Andrew Dunstan  writes:
>   
>> Tom Lane wrote:
>>     
>>> You should be able to remove CONVERT as a grammar keyword altogether
>>> -- the remaining production for CONVERT as a function name seems dead
>>> weight now (not to mention that it prevents having user-defined
>>> functions named CONVERT).
>>>       
>
>   
>> I wonderted a bit about that. I thought it might be better to leave it 
>> in case we wanted to put back "convert using" when we have better 
>> support for multiple encodings (and maybe when we understand better what 
>> it is actually supposed to do).
>>     
>
> Well, we could always put it back when we need it --- in the meantime,
> every extra keyword is some fractional drag on parsing performance.
>
> In any case I think the remaining production is probably wrong because
> it constrains the function to be in pg_catalog schema, when there is
> no grammatical evidence that it should be special.
>   

OK, fix committed doing this.

cheers

andrew

FAQ