[mapserver-users] WFS error

Rahkonen Jukka Jukka.Rahkonen at mmmtike.fi
Wed Oct 28 11:14:55 PDT 2009


Hi,

It is not totally clear for me where the data for the layer local_priority_projects are. Do you perhaps have it locally on your server?  Now it looks like you have set up a circular WFS service at www.tarpogis.org which is trying to read and cascade WFS data from the same service at www.tarpogis.org.

When creating WFS service I suggest to test is first with WMS.  When you can see the layer as a map through WMS you know that reading the source data is successful.  After that you can continue to WFS.

-Jukka Rahkonen-

S D Barnes wrote:
 
> Hi. I'm a rote beginner at MapServer, but I've run into a problem that I
can't find a reference for online.  I'm attempting to set up a WFS, but I
keep on getting this error spit back at me when doing a getfeature:

 

 <?xml version="1.0" encoding="ISO-8859-1" ?> 

 
<http://www.tarpogis.org/bin/mapserv?map=%2Fusr%2Flocal%2Fapache2%2Fhtdocs%2
Fdocs_maps%2Ftarpo%2Fwfs2.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=getfeature&T
YPENAME=local_priority_projects> - <ServiceExceptionReport version="1.2.0"
xmlns="http://www.opengis.net/ogc"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.opengis.net/ogc
http://schemas.opengis.net/wfs/1.0.0/OGC-exception.xsd">

  <ServiceException code="NoApplicableCode"
locator="mapserv">msWFSGetFeature(): WFS server error. ms_error->code not
found msWFSLayerWhichShapes(): WFS connection error. WFS request produced
unexpected output (junk?) for layer
local_priority_projects.</ServiceException> 

  </ServiceExceptionReport>

 

A getcapabilities request comes back fine, but not a getfeature request.
>From what I've read it looks as though the getfeature query is returning a
null set.  I'm not sure what is wrong, but my bet is that it's some sort of
beginner's mistake.  Any help would be most appreciated.  Here's the
mapfile:

 

 

NAME "TARPO_WFS"

STATUS ON

SIZE 400 300

SYMBOLSET "/usr/local/apache2/htdocs/docs_maps/etc/symbols.txt"

EXTENT -79.765391 34.800377 -78.831664 36.167575

UNITS FEET

SHAPEPATH "/arcgis/data/rpo/"

IMAGECOLOR 255 255 255

FONTSET "/usr/local/apache2/htdocs/docs_maps/etc/fonts.txt"

 

WEB

  IMAGEPATH "/usr/local/apache2/htdocs/docs_maps/tmp/"

  IMAGEURL "/docs_maps/tmp/"

  METADATA

    "wfs_title"            "TARPO Local Priority Projects"  ## REQUIRED

    "wfs_onlineresource"   "http://www.tarpogis.org/bin/mapserv.exe?"  ##
Recommended

    "wfs_srs"              "EPSG:4326"  ## Recommended

  END

END

 

PROJECTION

  "init=epsg:4326"

END

 

LAYER

  NAME "local_priority_projects"

  METADATA

    "wfs_version" "1.0.0"

    "wfs_title"    "TARPO Local Priority Projects" ## REQUIRED

    "wfs_srs"        "EPSG: 4326"

    "wfs_typename" "local_priority_projects"

    "wfs_request_method" "GET"

    "wfs_service" "WFS"

    "wfs_extent" "-79.765391 34.800377 -78.831664 36.167575"

    "gml_featureid" "FID" ## REQUIRED

    "gml_include_items" "all"  ## Optional (serves all attributes for layer)

  END

  TYPE LINE

  STATUS DEFAULT

  CONNECTIONTYPE WFS

  CONNECTION
"http://www.tarpogis.org/bin/mapserv?map=%2Fusr%2Flocal%2Fapache2%2Fhtdocs%2
Fdocs_maps%2Ftarpo%2Fwfs.map&"

  STATUS DEFAULT

  DATA local_priority_projects

  PROJECTION

    "init=epsg:4326"

  END

  DUMP TRUE           ## REQUIRED

  CLASS

    NAME "OBJECTID"

    STYLE

      COLOR 32 32 32

    END

  END

END # Layer

 

END # Map File

 

**********************************************************

September D Barnes

Data & Design Services Manager

Triangle J Council of Governments

P O Box 12276

Research Triangle Park, NC 27709

Direct Line: 919.558.9405

Fax: 919.549.9390





More information about the MapServer-users mailing list