Re: NAB : insert into select distinct => when used on null, distinct causes loss of type knowledge - Mailing list pgsql-general
From Frank van Vugt
Subject Re: NAB : insert into select distinct => when used on null, distinct causes loss of type knowledge
Date
Msg-id 200408242337.02757.ftm.van.vugt@foxi.nl
Whole thread Raw
In response to Re: NAB : insert into select distinct => when used on null, distinct causes loss of type knowledge  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
Hi Tom,

> No, because it never had any: NULL is typeless (type UNKNOWN, to the
> parser). But to do a DISTINCT, the parser has to assign datatypes to all the
> columns (to determine the comparison rules).  The default assumption for an
> UNKNOWN constant is type TEXT.

I grok, thanks for the quick reply.



--
Best,




Frank.


pgsql-general by date:

Previous
From: "Christine Desmuke"
Date:
Subject: Gentoo for production DB server?
Next
From: Greg Donald
Date:
Subject: Re: Gentoo for production DB server?