Re: > and >= give the same result - Mailing list pgsql-novice

From Frank Bax
Subject Re: > and >= give the same result
Date
Msg-id 4EFC6FB5.8050201@sympatico.ca
Whole thread Raw
In response to > and >= give the same result  ("Jean-Yves F. Barbier" <12ukwn@gmail.com>)
Responses Re: > and >= give the same result
Re: > and >= give the same result
List pgsql-novice
On 12/29/11 08:15, Jean-Yves F. Barbier wrote:
> Hi list,
>
> I'm trying to help a friend with his queries and I've something
> strange (well, to me:):
>
> SELECT * FROM tb1 WHERE note>  'y';
>
> returns the *same* result as:
>
> SELECT * FROM tb1 WHERE note>= 'y';
>
> There's something wrong: I though I'd have:
> 1st qry: z%
> 2nd qry: y% and z%
>
> What is wrong with using '>'&| '>=' with strings?
>
> I also know there's a page talking about that in the docs, but I
> can't find it.


The string 'y%' is greater than 'y'! Therefore, both queries will return
y% and z% - where is the problem?

pgsql-novice by date:

Previous
From: "Mariana Damova"
Date:
Subject: Login role
Next
From: "Jean-Yves F. Barbier"
Date:
Subject: Re: > and >= give the same result