[Mapserver-users] Upgrade to 4.0.1 query problem

Wim Blanken PI wim.blanken at planet.nl
Fri Apr 2 02:28:43 EST 2004


This is a multi-part message in MIME format.

--Boundary_(ID_3b5JH4LDK8Jmty0szSeYbw)
Content-type: text/plain; charset=iso-8859-1
Content-transfer-encoding: 7BIT

Hello John,

Maybe you have to set the TOLERANCE and TOLERANCEUNITS. See the mapfile documentation on the
main mapserver site for the usage. 
I had the same problem and this solved it.......

Regards,

Wim Blanken
  ----- Original Message ----- 
  From: John Wiley 
  To: mapserver-users at lists.gis.umn.edu 
  Sent: Friday, April 02, 2004 1:59 AM
  Subject: [Mapserver-users] Upgrade to 4.0.1 query problem


  I upgraded from 3.6 to 4.0.1 and can not query on lines or points just polygon objects return result from the templates.  Can someone point me in the right direction... I've included a piece of my map file... for layer Ppoints... Please help

  #
  # Start of map file
  #
  NAME Pville
  STATUS ON
  SIZE 600 600
  EXTENT 401500 5461000 410000 5466600
  UNITS METERS
  FONTSET "C:\Inetpub\wwwroot\Parksville\fonts\fonts.list"
  SHAPEPATH "data"
  IMAGECOLOR 255 255 255

  # you may need to change this to match your MapServer build
  #IMAGETYPE PNG

  #
  # Projection definition, consult the PROJ.4 documentation for parameter discussion
  #
  #PROJECTION
  #  "proj=utm"
  #  "ellps=GRS80"
  #  "zone=15"
  #  "north"
  #  "no_defs"
  #
  #  OR: 
  #
  #  "init=epsg:26915"
  #END

  #
  # Start of web interface definition (including WMS enabling metadata)
  #
  WEB
    HEADER Pville_header.html
    TEMPLATE Pville.html
    FOOTER Pville_footer.html
    MINSCALE 1000
    MAXSCALE 155000
    IMAGEPATH "set in Pville_init.html"
    IMAGEURL "set in Pville_init.html"
    METADATA
      WMS_TITLE "UMN MapServer Parksville BC"
      WMS_ABSTRACT "This is the UMN MapServer application for the City of Parksville located on Vancouver Island."
      WMS_ACCESSCONSTRAINTS none

      # change this value to match your setup
      WMS_ONLINERESOURCE "http://localhost/Parksville/Pville_init.html"

      WMS_SRS "EPSG:26915"
    END
  END

  QUERYMAP
    SIZE 200 200
    STATUS ON
    STYLE HILITE
    COLOR 255 0 0
  END

  #
  # Start of reference map
  #
  REFERENCE
    IMAGE graphics/reference.gif
    EXTENT 401500 5461000 410000 5466600
    SIZE 120 120
    STATUS ON
    COLOR -1 -1 -1
    OUTLINECOLOR 255 0 0
  END

  #
  # Start of legend
  #
  LEGEND
    KEYSIZE 12 12
    LABEL
      TYPE BITMAP
      SIZE MEDIUM
      COLOR 0 0 89
    END
    STATUS ON
  END

  #
  # Start of scalebar
  #
  SCALEBAR
    IMAGECOLOR 255 255 255
    LABEL
      COLOR 0 0 0
      SIZE tiny    
    END
    STYLE 1
    SIZE 80 2
    COLOR 0 0 0
    UNITS METERS
    INTERVALS 1
    TRANSPARENT FALSE
    STATUS EMBED
    POSITION LR
  END

  #
  # Start of symbol definitions (we're only using a few)
  #
  SYMBOL
    NAME 'circle'
    TYPE ELLIPSE
    POINTS 1 1 END
    FILLED TRUE
  END

  # Rem March9,04
  # Start of layer definitions
  #
  LAYER
    NAME Ptest
    TYPE RASTER
    STATUS OFF
    DATA test01.tif
    PROCESSING "BANDS=1,2,3"
    OFFSITE 71 74 65
  END #LAYER  
    
  LAYER
     NAME Pparks
     TYPE POLYGON
     STATUS OFF
     DATA Pparks
     LABELITEM "NAME"
     LABELMAXSCALE 5000
     CLASS
       NAME Parks
       COLOR 40 195 48
       TEMPLATE "Parks.html"
       LABEL
         MINFEATURESIZE 40
         MINDISTANCE 100
         BUFFER 10
         ANGLE AUTO
         POSITION AUTO
         SIZE MEDIUM
         COLOR 0 0 0         
       END #LABEL      
     END #CLASS  
     HEADER "Parks_header.html"
     FOOTER "Parks_footer.html"   
  END #LAYER

  LAYER
    NAME Pwatercourse
    TYPE LINE
    STATUS OFF
    DATA Pwatercourse
    CLASS
      NAME Watercourse
      COLOR 49 117 185
    END #CLASS 
  END #LAYER


  LAYER
    NAME Pwatflow
    TYPE POLYGON
    STATUS DEFAULT
    DATA Pwatflow
    CLASS
      NAME Pwatflow
      COLOR 49 37 185
    END #CLASS  
  END #LAYER


  LAYER
    NAME Ppoints
    TYPE POINT
    DATA Ppoints
    STATUS DEFAULT
    LABELITEM "NAME"
    LABELMAXSCALE 2000
    CLASS
      NAME 'Places'
      TEMPLATE "\Points.html"
      STYLE
        COLOR 128 255 164
        SYMBOL 'circle'
        SIZE 7
      END #STYLE
      LABEL
        MINFEATURESIZE 10
        MINDISTANCE 20
        BUFFER 5
        ANGLE AUTO
        POSITION AUTO
        SIZE SMALL
        COLOR 128 255 164
      END #LABEL
    END #CLASS
    HEADER "Points_header.html"
    FOOTER "Points_footer.html"  
  END #LAYER
  ... and on to the end...

--Boundary_(ID_3b5JH4LDK8Jmty0szSeYbw)
Content-type: text/html; charset=iso-8859-1
Content-transfer-encoding: 7BIT

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2800.1106" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY style="MARGIN-TOP: 2px; FONT: 8pt Tahoma; MARGIN-LEFT: 2px" 
bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Hello John,</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Maybe you have to set the TOLERANCE and 
TOLERANCEUNITS. See the mapfile documentation on the</FONT></DIV>
<DIV><FONT face=Arial size=2>main mapserver site for the usage. </FONT></DIV>
<DIV><FONT face=Arial size=2>I had the same </FONT><FONT face=Arial 
size=2>problem and this solved it.......</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Regards,</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Wim Blanken</FONT></DIV>
<BLOCKQUOTE dir=ltr 
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
  <DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
  <DIV 
  style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B> 
  <A title=JWiley at city.parksville.bc.ca 
  href="mailto:JWiley at city.parksville.bc.ca">John Wiley</A> </DIV>
  <DIV style="FONT: 10pt arial"><B>To:</B> <A 
  title=mapserver-users at lists.gis.umn.edu 
  href="mailto:mapserver-users at lists.gis.umn.edu">mapserver-users at lists.gis.umn.edu</A> 
  </DIV>
  <DIV style="FONT: 10pt arial"><B>Sent:</B> Friday, April 02, 2004 1:59 
AM</DIV>
  <DIV style="FONT: 10pt arial"><B>Subject:</B> [Mapserver-users] Upgrade to 
  4.0.1 query problem</DIV>
  <DIV><BR></DIV>
  <DIV><FONT size=2>I upgraded from 3.6 to 4.0.1 and can not query on lines or 
  points just polygon objects return result from the templates.&nbsp; Can 
  someone point me in the right direction... I've included a piece of my map 
  file... for layer Ppoints... Please help</FONT></DIV>
  <DIV><FONT size=2></FONT>&nbsp;</DIV>
  <DIV>#<BR># Start of map file<BR>#<BR>NAME Pville<BR>STATUS ON<BR>SIZE 600 
  600<BR>EXTENT 401500 5461000 410000 5466600<BR>UNITS METERS<BR>FONTSET 
  "C:\Inetpub\wwwroot\Parksville\fonts\fonts.list"<BR>SHAPEPATH 
  "data"<BR>IMAGECOLOR 255 255 255</DIV>
  <DIV>&nbsp;</DIV>
  <DIV># you may need to change this to match your MapServer build<BR>#IMAGETYPE 
  PNG</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>#<BR># Projection definition, consult the PROJ.4 documentation for 
  parameter discussion<BR>#<BR>#PROJECTION<BR>#&nbsp; "proj=utm"<BR>#&nbsp; 
  "ellps=GRS80"<BR>#&nbsp; "zone=15"<BR>#&nbsp; "north"<BR>#&nbsp; 
  "no_defs"<BR>#<BR>#&nbsp; OR: <BR>#<BR>#&nbsp; "init=epsg:26915"<BR>#END</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>#<BR># Start of web interface definition (including WMS enabling 
  metadata)<BR>#<BR>WEB<BR>&nbsp; HEADER Pville_header.html<BR>&nbsp; TEMPLATE 
  Pville.html<BR>&nbsp; FOOTER Pville_footer.html<BR>&nbsp; MINSCALE 
  1000<BR>&nbsp; MAXSCALE 155000<BR>&nbsp; IMAGEPATH "set in 
  Pville_init.html"<BR>&nbsp; IMAGEURL "set in Pville_init.html"<BR>&nbsp; 
  METADATA<BR>&nbsp;&nbsp;&nbsp; WMS_TITLE "UMN MapServer Parksville 
  BC"<BR>&nbsp;&nbsp;&nbsp; WMS_ABSTRACT "This is the UMN MapServer application 
  for the City of Parksville located on Vancouver Island."<BR>&nbsp;&nbsp;&nbsp; 
  WMS_ACCESSCONSTRAINTS none</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>&nbsp;&nbsp;&nbsp; # change this value to match your 
  setup<BR>&nbsp;&nbsp;&nbsp; WMS_ONLINERESOURCE "<A 
  href="http://localhost/Parksville/Pville_init.html">http://localhost/Parksville/Pville_init.html</A>"</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>&nbsp;&nbsp;&nbsp; WMS_SRS "EPSG:26915"<BR>&nbsp; END<BR>END</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>QUERYMAP<BR>&nbsp; SIZE 200 200<BR>&nbsp; STATUS ON<BR>&nbsp; STYLE 
  HILITE<BR>&nbsp; COLOR 255 0 0<BR>END</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>#<BR># Start of reference map<BR>#<BR>REFERENCE<BR>&nbsp; IMAGE 
  graphics/reference.gif<BR>&nbsp; EXTENT 401500 5461000 410000 
  5466600<BR>&nbsp; SIZE 120 120<BR>&nbsp; STATUS ON<BR>&nbsp; COLOR -1 -1 
  -1<BR>&nbsp; OUTLINECOLOR 255 0 0<BR>END</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>#<BR># Start of legend<BR>#<BR>LEGEND<BR>&nbsp; KEYSIZE 12 12<BR>&nbsp; 
  LABEL<BR>&nbsp;&nbsp;&nbsp; TYPE BITMAP<BR>&nbsp;&nbsp;&nbsp; SIZE 
  MEDIUM<BR>&nbsp;&nbsp;&nbsp; COLOR 0 0 89<BR>&nbsp; END<BR>&nbsp; STATUS 
  ON<BR>END</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>#<BR># Start of scalebar<BR>#<BR>SCALEBAR<BR>&nbsp; IMAGECOLOR 255 255 
  255<BR>&nbsp; LABEL<BR>&nbsp;&nbsp;&nbsp; COLOR 0 0 0<BR>&nbsp;&nbsp;&nbsp; 
  SIZE tiny&nbsp;&nbsp;&nbsp; <BR>&nbsp; END<BR>&nbsp; STYLE 1<BR>&nbsp; SIZE 80 
  2<BR>&nbsp; COLOR 0 0 0<BR>&nbsp; UNITS METERS<BR>&nbsp; INTERVALS 1<BR>&nbsp; 
  TRANSPARENT FALSE<BR>&nbsp; STATUS EMBED<BR>&nbsp; POSITION LR<BR>END</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>#<BR># Start of symbol definitions (we're only using a 
  few)<BR>#<BR>SYMBOL<BR>&nbsp; NAME 'circle'<BR>&nbsp; TYPE ELLIPSE<BR>&nbsp; 
  POINTS 1 1 END<BR>&nbsp; FILLED TRUE<BR>END</DIV>
  <DIV>&nbsp;</DIV>
  <DIV># Rem March9,04<BR># Start of layer definitions<BR>#<BR>LAYER<BR>&nbsp; 
  NAME Ptest<BR>&nbsp; TYPE RASTER<BR>&nbsp; STATUS OFF<BR>&nbsp; DATA 
  test01.tif<BR>&nbsp; PROCESSING "BANDS=1,2,3"<BR>&nbsp; OFFSITE 71 74 
  65<BR>END #LAYER&nbsp; <BR>&nbsp; <BR>LAYER<BR>&nbsp;&nbsp; NAME 
  Pparks<BR>&nbsp;&nbsp; TYPE POLYGON<BR>&nbsp;&nbsp; STATUS OFF<BR>&nbsp;&nbsp; 
  DATA Pparks<BR>&nbsp;&nbsp; LABELITEM "NAME"<BR>&nbsp;&nbsp; LABELMAXSCALE 
  5000<BR>&nbsp;&nbsp; CLASS<BR>&nbsp;&nbsp;&nbsp;&nbsp; NAME 
  Parks<BR>&nbsp;&nbsp;&nbsp;&nbsp; COLOR 40 195 48<BR>&nbsp;&nbsp;&nbsp;&nbsp; 
  TEMPLATE "Parks.html"<BR>&nbsp;&nbsp;&nbsp;&nbsp; 
  LABEL<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MINFEATURESIZE 
  40<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MINDISTANCE 
  100<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BUFFER 
  10<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ANGLE 
  AUTO<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; POSITION 
  AUTO<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SIZE 
  MEDIUM<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; COLOR 0 0 
  0&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <BR>&nbsp;&nbsp;&nbsp;&nbsp; 
  END #LABEL&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <BR>&nbsp;&nbsp; END #CLASS&nbsp; 
  <BR>&nbsp;&nbsp; HEADER "Parks_header.html"<BR>&nbsp;&nbsp; FOOTER 
  "Parks_footer.html"&nbsp;&nbsp; <BR>END #LAYER</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>LAYER<BR>&nbsp; NAME Pwatercourse<BR>&nbsp; TYPE LINE<BR>&nbsp; STATUS 
  OFF<BR>&nbsp; DATA Pwatercourse<BR>&nbsp; CLASS<BR>&nbsp;&nbsp;&nbsp; NAME 
  Watercourse<BR>&nbsp;&nbsp;&nbsp; COLOR 49 117 185<BR>&nbsp; END #CLASS 
  <BR>END #LAYER</DIV>
  <DIV>&nbsp;</DIV>
  <DIV><BR>LAYER<BR>&nbsp; NAME Pwatflow<BR>&nbsp; TYPE POLYGON<BR>&nbsp; STATUS 
  DEFAULT<BR>&nbsp; DATA Pwatflow<BR>&nbsp; CLASS<BR>&nbsp;&nbsp;&nbsp; NAME 
  Pwatflow<BR>&nbsp;&nbsp;&nbsp; COLOR 49 37 185<BR>&nbsp; END #CLASS&nbsp; 
  <BR>END #LAYER</DIV>
  <DIV>&nbsp;</DIV>
  <DIV><BR>LAYER<BR>&nbsp; NAME Ppoints<BR>&nbsp; TYPE POINT<BR>&nbsp; DATA 
  Ppoints<BR>&nbsp; STATUS DEFAULT<BR>&nbsp; LABELITEM "NAME"<BR>&nbsp; 
  LABELMAXSCALE 2000<BR>&nbsp; CLASS<BR>&nbsp;&nbsp;&nbsp; NAME 
  'Places'<BR>&nbsp;&nbsp;&nbsp; TEMPLATE "\Points.html"<BR>&nbsp;&nbsp;&nbsp; 
  STYLE<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; COLOR 128 255 
  164<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SYMBOL 
  'circle'<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SIZE 7<BR>&nbsp;&nbsp;&nbsp; END 
  #STYLE<BR>&nbsp;&nbsp;&nbsp; LABEL<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  MINFEATURESIZE 10<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MINDISTANCE 
  20<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BUFFER 
  5<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ANGLE 
  AUTO<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; POSITION 
  AUTO<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SIZE 
  SMALL<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; COLOR 128 255 
  164<BR>&nbsp;&nbsp;&nbsp; END #LABEL<BR>&nbsp; END #CLASS<BR>&nbsp; HEADER 
  "Points_header.html"<BR>&nbsp; FOOTER "Points_footer.html"&nbsp; <BR>END 
  #LAYER<BR>... and on to the end...</DIV></BLOCKQUOTE></BODY></HTML>

--Boundary_(ID_3b5JH4LDK8Jmty0szSeYbw)--



More information about the mapserver-users mailing list