Search Postgresql Archives

Re: 'a' == 'a ' (Was: RE: [pgsql-advocacy] Oracle buys

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am Mittwoch, den 19.10.2005, 16:29 -0300 schrieb Marc G. Fournier:
> I'm CC'ng this over to -hackers ... Tom?  Comments?
> 
> On Wed, 19 Oct 2005, Dann Corbit wrote:
> 
> > Yes, clearly that is the wrong result according to the SQL standard.
> >
> > Here is a SQL*Server query:
> > select 1 where 'a' = 'a ' AND 'a' = 'a  ' AND 'a ' = 'a         '
> >
> > It returns (correctly): 1
> >
> >> -----Original Message-----
> >> From: pgsql-general-owner@xxxxxxxxxxxxxx [mailto:pgsql-general-
> >> owner@xxxxxxxxxxxxxx] On Behalf Of Marc G. Fournier
> >> Sent: Wednesday, October 19, 2005 11:41 AM
> >> To: Richard_D_Levine@xxxxxxxxxxxx
> >> Cc: pgsql-general@xxxxxxxxxxxxxx
> >> Subject: Re: [pgsql-advocacy]  Oracle buys Innobase
> >>
> >> On Wed, 19 Oct 2005, Richard_D_Levine@xxxxxxxxxxxx wrote:
> >>
> >>> I was referring to trailing blanks, but did not explicitly say it,
> >>> though showed it in the examples.  I am pretty sure that the SQL
> >>> standard says that trailing whitespace is insignificant in string
> >>> comparison.
> >>
> >> Then we are broken too :)
> >>
> >> # select 'a ' = 'a  ';
> >>   ?column?
> >> ----------
> >>   f
> >> (1 row)


experiment=# SELECT 'a '::char = 'a  '::char;
 ?column?
----------
 t



---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

               http://archives.postgresql.org

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux