Shapefile field problem

Abe Gillespie agillesp at VT.EDU
Mon Dec 6 20:14:25 EST 2004


It's a regular shapefile.  I think I've mostly narrowed it down.  It
seems to me (though I may be completely off) that MapServer loads the
first record of the DBF in order to get the field definitions.  If the
first record has a string field and the value is zero length it won't
give me the field (though the field count is always correct).  In
addition, it won't give me any fields after that either.  If, however,
I make sure that field has some value (a dash, an "x", whatever) then
the field definition will come in correctly.  I still haven't narrowed
down a problematic number field though.  Mind you, this is all done in
MapServer PHP v. 4.2.0.

-Abe

On Dec 6, 2004, at 6:15 PM, Daniel Morissette wrote:

> Abe Gillespie wrote:
>> A good amount of fields aren't showing up in MapServer for me.  I use
>> the following PHP script to dump out all layers and their fields for
>> debugging.  Does MapServer have problems with certain data types or
>> certain values in a row?
>>
>
> Are you using a tiled shapefile layer or is this a regular shapefile
> layer?
>
> --
> ------------------------------------------------------------
>  Daniel Morissette               dmorissette at dmsolutions.ca
>  DM Solutions Group              http://www.dmsolutions.ca/
> ------------------------------------------------------------
>



More information about the mapserver-users mailing list