I have a few questions regarding WFS and large PostGIS databases (mapfile 
below):
*) When I run a getFeature request on my layer, I get the following GML:
<wfs:FeatureCollection xsi:schemaLocation="http://www.opengis.net/wfs 
http://schemas.opengis.net/wfs/1.0.0/WFS-basic.xsd                         
http://mapserver.gis.umn.edu/mapserver 
http://localhost/cgi-bin/mapserv.exe?map=test/testWFS.map&SERVICE=WFS&VERSION=1.0.0&REQUEST=DescribeFeatureType&TYPENAME=test&OUTPUTFORMAT=XMLSCHEMA";>
<gml:boundedBy>
<gml:null>missing</gml:null>
</gml:boundedBy>
</wfs:FeatureCollection>

However, if I connect with uDig, I do see features returned. Why do I not see 
the XML when I request it from my browser?

*) Also, I've tried using FE to filter down the dataset with no luck. In this 
case, since the dataset has millions of features, I'm curious how the FE logic 
works. Will it attempt to retrieve the entire dataset and only then apply the 
filter? Or will it apply the filter in SQL. Likewise with the wfs_maxfeatures 
metadata - will that only apply after it loads the dataset or does it add a 
"limit" clause to the sql query?

Thanks,
-Chris

NAME testWFSService
STATUS ON
SIZE 800 600
EXTENT -180 -90 180 90
UNITS DD
IMAGECOLOR 255 255 255

WEB
  IMAGEPATH "/ms4w/tmp/ms_tmp/" 
  IMAGEURL "/ms4w/tmp/"
  METADATA
    "wfs_title"            "Test"  ## REQUIRED
        "wfs_maxfeatures"               "4000"
        "wfs_request_method"    "get"
        "wfs_extent"   "-180 -90 180 90"
#    "wfs_onlineresource"   "http://localhost/cgi-bin/mapserv.exe?";  ## 
Recommended
    "wfs_srs"              "EPSG:4326"  ## Recommended
#    "ows_schemas_location" "http://ogc.dmsolutions.ca";  ## Optional
  END
END

PROJECTION
  "init=epsg:4236"
END

LAYER
  NAME test
  METADATA
    "wfs_title"    "test" ## REQUIRED
    "gml_featureid" "oid" ## REQUIRED
        "wfs_featureid" "oid" ## REQUIRED
    "gml_include_items" "all"  ## Optional (serves all attributes for layer)
        "wfs_extent"   "-180 -90 180 90"
  END
  EXTENT -180 -90 180 90
  
  PROJECTION
  "init=epsg:4236"
END
  TYPE POINT
  STATUS DEFAULT
  CONNECTIONTYPE POSTGIS
  CONNECTION "host=myhost dbname=test user=test password=pass port=5432"
  DATA "geom from mytable using unique oid using SRID=4326"
  
  DUMP TRUE           ## REQUIRED
   CLASS
      METADATA
      END
      STYLE
        ANGLE 360
        OUTLINECOLOR 255 0 0
                COLOR 255 0 0
        SYMBOL 0
        WIDTH 4
      END
    END
  
END # Layer

END # Map File

Reply via email to