Skip site navigation (1) Skip section navigation (2)

Re: BUG #4416: Between operator is not working as expected

From: Stephan Szabo <sszabo(at)megazone(dot)bigpanda(dot)com>
To: Murali <muralidoss(at)rediffmail(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #4416: Between operator is not working as expected
Date: 2008-09-14 01:41:45
Message-ID: 20080913183848.P58785@megazone.bigpanda.com (view raw or flat)
Thread:
Lists: pgsql-bugs
On Sat, 13 Sep 2008, Murali wrote:

>
> The following bug has been logged online:
>
> Bug reference:      4416
> Logged by:          Murali
> Email address:      muralidoss(at)rediffmail(dot)com
> PostgreSQL version: 8.2.6
> Operating system:   Linux
> Description:        Between operator is not working as expected
> Details:
>
> Actually sql works fine in solaris with 8.2.5 postgresql version but same
> sql query is not working in linux.
>
> fyi...both the database in linux and solaris are having similar structure
> and data too.
>
> Here is the query i am try to execute
>
> select * from table1 where col1 between 'SM' and 'SM~';
>
> Please guide me

My guess would be that the behavior of the collations on the two machines
are different. It looks like you're expecting "C" style byte order
comparisons, but your linux box probably is using a different collation.
What does "show LC_COLLATE;" give you from psql to both databases?


In response to

pgsql-bugs by date

Next:From: Peter EisentrautDate: 2008-09-15 07:29:36
Subject: Re: [BUGS] BUG #4279: Bad codepage in our web-site
Previous:From: MuraliDate: 2008-09-13 23:26:54
Subject: BUG #4416: Between operator is not working as expected

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group