Re: [BUGS] Oder by not working

2008-08-07 Thread Heikki Linnakangas
Subject: Re: [BUGS] Oder by not working Heikki Linnakangas wrote: Unlike on some systems, in PostgreSQL "ORDER BY 1" means order by the constant value "1", not the first column. Try "ORDER BY name". Oh, that's of course not correct at all. "ORDER BY 1&qu

Re: [BUGS] Oder by not working

2008-08-07 Thread Blanco, Jose
So is there no way to make oder by work with names? -Original Message- From: Heikki Linnakangas [mailto:[EMAIL PROTECTED] Sent: Thursday, August 07, 2008 3:00 AM To: Blanco, Jose Cc: pgsql-bugs@postgresql.org Subject: Re: [BUGS] Oder by not working Heikki Linnakangas wrote: > Unlike

Re: [BUGS] Oder by not working

2008-08-07 Thread Heikki Linnakangas
Heikki Linnakangas wrote: Unlike on some systems, in PostgreSQL "ORDER BY 1" means order by the constant value "1", not the first column. Try "ORDER BY name". Oh, that's of course not correct at all. "ORDER BY 1" does indeed mean order by first column. I don't know what I was thinking, --

Re: [BUGS] Oder by not working

2008-08-06 Thread Heikki Linnakangas
Blanco, Jose wrote: Which as you can see is not really the desired behavior. I created a test table and loaded these values into a field of type text, and then issued the following query: select * from test order by 1; name Ta, A Tab, A Ta, Z (3 rows) Unlike on some system

Re: [BUGS] Oder by not working

2008-08-06 Thread Tom Lane
"Blanco, Jose" <[EMAIL PROTECTED]> writes: > Suppose we have the following 3 names in a table: > Ta, A > Ta, Z > Tab, A > I would expect them to show up in the oder shown above when odering by > by name, but instead I get: > Ta, A > Tab, A > Ta, Z This is not a bug. Or at least you have

[BUGS] Oder by not working

2008-08-06 Thread Blanco, Jose
I was hoping that the a newer version of postgres ( 8.1.11 ) would solve the problem we see when we use order by to get a listing of names. Let me explain the problem. Suppose we have the following 3 names in a table: Ta, A Ta, Z Tab, A I would expect them to show up in the oder shown above