Unix Technical Forum

Re: [GENERAL] 'a' == 'a '

This is a discussion on Re: [GENERAL] 'a' == 'a ' within the pgsql Hackers forums, part of the PostgreSQL category; --> > -----Original Message----- > From: Bruce Momjian [mailto gman@candle.pha.pa.us] > Sent: Monday, October 24, 2005 5:57 PM > To: ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Hackers

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-11-2008, 07:24 AM
Dann Corbit
 
Posts: n/a
Default Re: [GENERAL] 'a' == 'a '

> -----Original Message-----
> From: Bruce Momjian [mailtogman@candle.pha.pa.us]
> Sent: Monday, October 24, 2005 5:57 PM
> To: Dann Corbit
> Cc: Tom Lane; Richard_D_Levine@raytheon.com; general@postgresql.org;
> pgsql-hackers@postgresql.org
> Subject: Re: [GENERAL] [HACKERS] 'a' == 'a '
>
> Dann Corbit wrote:
> > Document the collating sequences used for the character types.

>
> Sorry, I don't understand that. What does it mean?


According to the standard, comparisons against character types are
supposed to PAD with either <space> or <PAD CHAR> according to the
collating sequence and not according to the data type.

Since the padding behavior of PosgreSQL comparisons for character types
is different according to the data type and not the collating sequence,
what is needed is simply to define the collating sequence used for
different character types.


---------------------------(end of broadcast)---------------------------
TIP 6: explain analyze is your friend

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-11-2008, 07:24 AM
Bruce Momjian
 
Posts: n/a
Default Re: [GENERAL] 'a' == 'a '

Dann Corbit wrote:
> > -----Original Message-----
> > From: Bruce Momjian [mailtogman@candle.pha.pa.us]
> > Sent: Monday, October 24, 2005 5:57 PM
> > To: Dann Corbit
> > Cc: Tom Lane; Richard_D_Levine@raytheon.com; general@postgresql.org;
> > pgsql-hackers@postgresql.org
> > Subject: Re: [GENERAL] [HACKERS] 'a' == 'a '
> >
> > Dann Corbit wrote:
> > > Document the collating sequences used for the character types.

> >
> > Sorry, I don't understand that. What does it mean?

>
> According to the standard, comparisons against character types are
> supposed to PAD with either <space> or <PAD CHAR> according to the
> collating sequence and not according to the data type.
>
> Since the padding behavior of PosgreSQL comparisons for character types
> is different according to the data type and not the collating sequence,
> what is needed is simply to define the collating sequence used for
> different character types.


But isn't collating sequence related to ordering? How does this relate
to padding?

--
Bruce Momjian | http://candle.pha.pa.us
pgman@candle.pha.pa.us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

---------------------------(end of broadcast)---------------------------
TIP 6: explain analyze is your friend

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 06:53 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com