Shapefile layer filter to sort objects ?

Ken Lord kenlord at GMAIL.COM
Mon Dec 12 15:17:32 EST 2005


Hi Laurent,

If you just need to sort the data once, not on-the-fly, use the
sortshp utility program that comes with mapserver.

I had the same problem symbolizing soil samples by element (gold,
silver etc) with a layer that allowed you to switch between elements
displayed using one layer in the mapfile with some variable
substitution.  To display properly for all the elements, the data had
to be sorted on-the-fly by the element selected for display.

In this case I placed the data in PostGIS and used variable
substitution in the mapfile (in the SQL query for that layer) to order
the data by the appropriate attribute.


Cheers,
Ken Lord
Vancouver BC

On 12/12/05, Laurent Jégou <jegou at univ-tlse2.fr> wrote:
> Hi list,
>
> I'm using the SIZEITEM parameter of the STYLE object to generate
> proportional symbols based on attributes values. It's working nicely
> since i discovered that the SYMBOLSCALE parameter of the LAYER object
> must be present. I'm now wondering if there's a way to sort the symbols
> objects in decreasing order, to have the small ones drawn above the big
> ones. With a database geometry source i can use a FILTER parameter, but
> with a shapefile source ?
>
> Thanks for your help,
>
> Laurent
>
> --
> Laurent Jégou
> IGE Cartographe
> UTM - Dépt. Géographie
> 31058 TOULOUSE Cedex 9 - 05.61.50.43.89
> http://www.univ-tlse2.fr/geoprdc
> http://www.geotests.net/blog
>



More information about the mapserver-users mailing list