| From: | Heikki Linnakangas <heikki(at)enterprisedb(dot)com> |
|---|---|
| To: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
| Cc: | pgsql-hackers(at)postgresql(dot)org |
| Subject: | Re: Weird type selection choice |
| Date: | 2007-11-07 10:47:00 |
| Message-ID: | 473197A4.1040903@enterprisedb.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Peter Eisentraut wrote:
> I wrote:
>> I noticed this problem in 8.2 and 8.3:
>>
>> pei=# select mod( trunc( 1 ), 2 );
>> ERROR: 42883: function mod(double precision, integer) does not exist
>> LINE 1: select mod( trunc( 1 ), 2 );
>> ^
>
> I suppose there will be little interest in including the obvious solution,
> namely
>
> CREATE FUNCTION pg_catalog.trunc(int) RETURNS int AS $$ SELECT $1; $$ LANGUAGE
> SQL STRICT IMMUTABLE;
It does sound totally useless...
Why would you run a query like that in the first place? It seems like a
useless query as it is. Is there a bigger story behind it?
--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com
| From | Date | Subject | |
|---|---|---|---|
| Next Message | J=?ISO-8859-1?B?9g==?=rg Beyer | 2007-11-07 11:13:05 | Re: Bug: --with-libxml does not take a location |
| Previous Message | Heikki Linnakangas | 2007-11-07 10:45:22 | Re: Visibility map thoughts |