Hi List,

I am new to the list and have been trying to setup MapServer's SOS Server to 
serve some observation data.  I have created a map file and managed to have 
GetCapabilities working.  But when trying out the GetObservation, I am 
confused...  not much helpful documentation around and have found this 
discussion from the old SOS User forum : 
http://osgeo-org.1803224.n2.nabble.com/SOS-disconnect-td1992064.html.  However, 
still confused on how to map a database column to SOS output !?!?


Metadata for the layer in my map file :

 METADATA
 "sos_value_alias"  "value_test"  ## value is the name of the db clumn
 "sos_value_componenturl" "http://test.org#value_test";
 "sos_procedure"   "unknown"
 "sos_offering_id"  "waterstorage"
 "sos_offering_description" "value_test"
 "sos_observedproperty_id" "9"
 "sos_describesensor_url" "http://localhost/TEST123.xml";
 "sos_srs"   "init=epsg:4283"
 "sos_offering_timeextent" "1900/2010"


The database connection is successful and the GetCapabilities return the 
following sos information :

- <sos:Contents>
- <sos:ObservationOfferingList>
- <sos:ObservationOffering gml:id="waterstorage">
  <gml:description>value_test</gml:description>
- <!-- WARNING: Optional metadata "sos_offering_name" missing for gml:name
  -->
  <gml:srsName>EPSG:4326</gml:srsName>
- <!-- WARNING: Optional metadata "sos_offering_intendedapplication" missing 
for sos:intendedApplication
  -->
- <sos:time>
- <gml:TimePeriod>
  <gml:beginPosition>1900</gml:beginPosition>
  <gml:endPosition>2010</gml:endPosition>
  </gml:TimePeriod>
  </sos:time>
  <sos:procedure xlink:href="urn:ogc:def:procedure:unknown" />
- <sos:observedProperty>
- <swe:CompositePhenomenon gml:id="9" dimension="7">
  <swe:component xlink:href="urn:ogc:def:property:OGC-SWE:1:feature" />
  <swe:component xlink:href="urn:ogc:def:property:OGC-SWE:1:identifier" />
  <swe:component xlink:href="urn:ogc:def:property:OGC-SWE:1:ftype" />
  <swe:component xlink:href="urn:ogc:def:property:OGC-SWE:1:value_test" />
  <swe:component xlink:href="urn:ogc:def:property:OGC-SWE:1:type" />
  <swe:component xlink:href="urn:ogc:def:property:OGC-SWE:1:description" />
  <swe:component xlink:href="urn:ogc:def:property:OGC-SWE:1:yearofcompletion" />
  </swe:CompositePhenomenon>
  </sos:observedProperty>
  <sos:featureOfInterest xlink:href="urn:ogc:def:feature:OGC-SWE:3:transient" />
  <sos:responseFormat>text/xml; subtype="om/1.0.0"</sos:responseFormat>
  <sos:resultModel>om:Observation</sos:resultModel>
  <sos:resultModel>om:Measurement</sos:resultModel>
  <sos:responseMode>inline</sos:responseMode>
  </sos:ObservationOffering>
  </sos:ObservationOfferingList>
  </sos:Contents>

GetObservation 
(http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/sos/sos_test.map&Request=GetObservation&service=SOS&OFFERING=waterstorage&observedproperty=9&version=1.0.0&responseFormat=text/xml;
 subtype="om/1.0.0") return the following :

  <?xml version="1.0" encoding="ISO-8859-1" ?>
- <om:ObservationCollection xmlns:gml="http://www.opengis.net/gml"; 
xmlns:ows="http://www.opengis.net/ows/1.1"; 
xmlns:swe="http://www.opengis.net/swe/1.0.1"; 
xmlns:xlink="http://www.w3.org/1999/xlink"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:sos="http://www.opengis.net/sos/1.0"; 
xmlns:ms="http://mapserver.gis.umn.edu/mapserver"; 
xmlns:om="http://www.opengis.net/om/1.0"; gml:id="waterstorage" 
xsi:schemaLocation="http://www.opengis.net/om/1.0 
http://schemas.opengis.net/om/1.0.0/om.xsd 
http://mapserver.gis.umn.edu/mapserver 
http://127.0.0.1/cgi-bin/mapserv.exe?map=c:/ms4w/apps/sos/sos_test.map&service=WFS&version=1.1.0&request=DescribeFeatureType&typename=test_sos_layer";>
  <gml:description 
xmlns:gml="http://www.opengis.net/gml";>value_test</gml:description>
  </om:ObservationCollection>



My quesions are :

1) How do I map a db clumn to a sos output ??   Do i have to create 
"sos_dbColumn_alias" for each column ?
2) What's the purpose of "sos_dbColumn_componenturl" ?  Do I need to create 
this for each dbColumn ?
3) I have map the  "sos_offering_description" "value_test", why does the 
getCapabilities and getObservation return "value_test" as a constant rather 
then retrieving data from the database ?


Appreciave if someone could point out what is the problem of the map file or 
point me to some useful documentation or tutorial on set up SOS in MapServer.




Thanks & Regards,


Florence Tan
Research Projects Officer | ASRDC
CSIRO Earth Science and Resource Engineering

Phone: +61 8 6436 8802 | Fax: +61 8 6436 8559
[email protected]<mailto:[email protected]> | www.csiro.au
Address: Australian Resources Research Centre, 26 Dick Perry Avenue, Kensington 
WA 6151

PLEASE NOTE
The information contained in this email may be confidential or privileged. Any 
unauthorised use or disclosure is prohibited. If you have received this email 
in error, please delete it immediately and notify the sender by return email. 
Thank you. To the extent permitted by law, CSIRO does not represent, warrant 
and/or guarantee that the integrity of this communication has been maintained 
or that the communication is free of errors, virus, interception or 
interference.

Please consider the environment before printing this email.


_______________________________________________
mapserver-users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Reply via email to