order by in c (libpq)? - Mailing list pgsql-interfaces

From Ken Plumbly
Subject order by in c (libpq)?
Date
Msg-id 3765C0C7.C401342E@ocol.com
Whole thread Raw
Responses Re: [INTERFACES] order by in c (libpq)?  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-interfaces
Hi All,  I am writing an app in c,  everything works fine except for the

order by in my query.

I am sending the query thusly:

sprintf(querystr, "select * from %s order by %s", table, field);

However the query always comeback in the order in which the data was
originally entered into the data base.

The variable field does actually contain a valid field name,  I have
checked
it.

Any ideas????

Ken
kvp@ocol.com


pgsql-interfaces by date:

Previous
From: Vikrant Rathore
Date:
Subject: Mail about typecast
Next
From: Sergio Perez
Date:
Subject: problems with pgaccess 0.93 and postgres 6.3