[Mapserver-users] postgis order by

David Mitchell david.mitchell at telogis.com
Mon Mar 15 15:07:21 EST 2004


I use order by in my mapfiles, I use it like so:

DATA "the_geom from (SELECT * FROM <table> ORDER BY ...) as
foo USING UNIQUE id USING SRID=-1"

This works fine for me. What version of mapserver are you using? I use 
mapserver 4.0.1 on linux

David

Nick Petersen-Bergeron wrote:
> The order by seems to be ignored doing this.
> 
> 
> At 10:01 AM 3/15/2004 -0800, David Blasby wrote:
> 
>> Nick Petersen-Bergeron wrote:Nick Petersen-Bergeron <bergeron at zedxinc.com>
>>
>>> When using postgis/postgres with mapserver, is it possible to use an 
>>> order by statement to determine the order in which your geometries 
>>> are drawn?  If I put the order by in the data portion of the layer, 
>>> no errors are thrown, but the order by seems to be ignored.  If I 
>>> include it in the filter portion of the layer, an error is thrown and 
>>> nothing is drawn.  Any help would be appreciated.
>>
>>
>> Try something like:
>>
>> DATA "the_geom from (SELECT id,the_geom FROM <table> ORDER BY ...) as 
>> foo USING UNIQUE id USING SRID=123"
>>
>> dave
> 
> 
> Nick Petersen-Bergeron
> Developer
> 
> ZedX Inc.
> 369 Rolling Ridge Drive
> Bellefonte, PA. 16823
> 
> _______________________________________________
> Mapserver-users mailing list
> Mapserver-users at lists.gis.umn.edu
> http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
> 
> 


-- 
David Mitchell
Software Engineer
Telogis

NOTICE:
This message (including any attachments) contains CONFIDENTIAL
INFORMATION intended for a specific individual and purpose, and
is protected by law.  If you are not the intended recipient,
you should delete this message and are hereby notified that any
disclosure, copying, or distribution of this message, or the
taking of any action based on it, is strictly prohibited.



More information about the mapserver-users mailing list