[mapserver-users] DBASE Error at shapefile call
Stefan Stern
mail2stern at gmx.net
Sat Sep 14 13:31:34 PDT 2002
Hi all,
I ran into a strange behavior of mapserver.
I want to display a shapefile that is created by the following sample
dataset table:
#################################################
id,description,samplesites,x_british_survey,y_british_survey
T1,"u/s of N-Y-F",T,267009,196614
T2,"At mouth of N-Y-F",T,267000,196592
T3,"d/s of N-Y-F",T,266985,196585
#################################################
Just a table that stores Id, description, samplesites and GPS coordinates.
1. The following extract of my mapfile works fine and the layer displays
the T1 GPS Point:
#####################################
LAYER # start of the gps layer object
NAME "gps"
DATA "gps140902"
STATUS DEFAULT
TYPE POINT
CLASSITEM "Id" # attribut
CLASS # gps points class
NAME "f_gps"
EXPRESSION "T1"
COLOR 255 0 0
SYMBOL 'circle'
SIZE 10
END # end of Gps class object
END # end Layer
######################################
2.
BUT, when I change the CLASSITEM to "Samplesites", which is a proper
identifier as well:
####################################
LAYER # start of the gps layer object
NAME "gps"
DATA "gps140902"
STATUS DEFAULT
TYPE POINT
CLASSITEM "Samplesites" # attribut
CLASS # gps points class
NAME "f_gps"
EXPRESSION "T"
COLOR 255 0 0
SYMBOL 'circle'
SIZE 10
END # end of Gps class object
####################################
the following error occurs:
########################
msDBFGetItemIndex(): DBASE file error. Item 'Samplesites' not found.
###########################
I tried "SAMPLESITES" and "samplesites" unsuccessfully as well.
I guess Mapserver can't deal with my created Shapefile set.
Where does the "msDBFGetItemIndex()" function look for the identifier
(e.g. Samplesites)? In the .dbf file or in the .shp file itself?
Thanks for any suggestions,
Best Regards,
Stefan Stern
More information about the MapServer-users
mailing list