<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html; charset=ISO-8859-1"
 http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
<font size="-1"><font face="Helvetica, Arial, sans-serif">Hello,<br>
<br>
Thanks, I've finally solved the problem. <br>
It was OpenLayers, not MapServer related, anyway your help was very
useful!<br>
<br>
BR,<br>
Attila</font></font><br>
<br>
2010.04.09. 15:08 keltez&eacute;ssel, Yewondwossen Assefa &iacute;rta:
<blockquote cite="mid:4BBF26B9.8090808@dmsolutions.ca" type="cite">Hi
There,
  <br>
  <br>
wfs post request should look like this:
  <br>
  <br>
&lt;?xml version="1.0" ?&gt;
  <br>
&lt;wfs:GetFeature service="WFS" version="1.1.0"
outputFormat="text/xml; subtype=gml/3.1.1"
xmlns:wfs=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/wfs">"http://www.opengis.net/wfs"</a>
xmlns:ogc=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/ogc">"http://www.opengis.net/ogc"</a>
xmlns:xsi=<a class="moz-txt-link-rfc2396E" href="http://www.w3.org/2001/XMLSchema-instance">"http://www.w3.org/2001/XMLSchema-instance"</a>
xsi:schemaLocation=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/wfs../wfs/1.1.0/WFS.xsd">"http://www.opengis.net/wfs
../wfs/1.1.0/WFS.xsd"</a>&gt;
  <br>
&lt;wfs:Query typeName="my_name"&gt;
  <br>
&lt;ogc:Filter&gt;
  <br>
...
  <br>
&lt;/ogc:Filter&gt;
  <br>
&lt;/wfs:Query&gt;
  <br>
&lt;wfs:Query typeName="my_layer2"&gt;
  <br>
&lt;ogc:Filter&gt;
  <br>
....
  <br>
&lt;/ogc:Filter&gt;
  <br>
&lt;/wfs:Query&gt;
  <br>
&lt;/wfs:GetFeature&gt;
  <br>
  <br>
You can check the xsds for more details at
<a class="moz-txt-link-freetext" href="http://schemas.opengis.net/wfs/">http://schemas.opengis.net/wfs/</a>
  <br>
  <br>
regards,
  <br>
  <br>
Attila BER&Eacute;NYI wrote:
  <br>
  <blockquote type="cite">Hi,
    <br>
    <br>
Thank you for your response, I'm able to request data from both layers
(typenames) this way, however I'd like to achieve this in OpenLayers.
So I've created a small demo application which uses XMLHttp to request
data from Mapserver.
    <br>
<a class="moz-txt-link-freetext" href="http://webgis.fmt.bme.hu/gfi/xml.html">http://webgis.fmt.bme.hu/gfi/xml.html</a>
    <br>
The requests are hard coded, please take a look at the source.
    <br>
    <br>
How could I achieve the below described functionality with XML
request(s)?
    <br>
    <br>
Thanks in advance,
    <br>
    <br>
BR,
    <br>
    <br>
Attila
    <br>
    <br>
2010.04.06. 15:42 keltez&eacute;ssel, Yewondwossen Assefa &iacute;rta:
    <br>
    <blockquote type="cite">The following URL on your server gives the
output for the 2 typenames I believe:
      <br>
      <br>
<a class="moz-txt-link-freetext" href="http://webgis.fmt.bme.hu/cgi-bin/mvmNew?SERVICE=WFS&amp;VERSION=1.1.0&amp;REQUEST=GetFeature&amp;TYPENAME=elteresek,elteresek2&amp;Filter=%28%3Cogc:Filter%20xmlns:ogc=%22http://www.opengis.net/ogc%22%3E%3Cogc:BBOX%3E%3Cogc:PropertyName%3EmsGeometry%3C/ogc:PropertyName%3E%3Cgml:Envelope%20xmlns:gml=%22http://www.opengis.net/gml%22%20srsName=%22EPSG:23700%22%3E%3Cgml:lowerCorner%3E649971.6696%20236508.4728%3C/gml:lowerCorner%3E%3Cgml:upperCorner%3E651559.1688%20237919.5832%3C/gml:upperCorner%3E%3C/gml:Envelope%3E%3C/ogc:BBOX%3E%3C/ogc:Filter%3E%29%28%3Cogc:Filter%20xmlns:ogc=%22http://www.opengis.net/ogc%22%3E%3Cogc:BBOX%3E%3Cogc:PropertyName%3EmsGeometry%3C/ogc:PropertyName%3E%3Cgml:Envelope%20xmlns:gml=%22http://www.opengis.net/gml%22%20srsName=%22EPSG:23700%22%3E%3Cgml:lowerCorner%3E649971.6696%20236508.4728%3C/gml:lowerCorner%3E%3Cgml:upperCorner%3E651559.1688%20237919.5832%3C/gml:upperCorner%3E%3C/gml:Envelope%3E%3C/ogc:BBOX%3E%3C/og
c:Filter%3E%29">http://webgis.fmt.bme.hu/cgi-bin/mvmNew?SERVICE=WFS&amp;VERSION=1.1.0&amp;REQUEST=GetFeature&amp;TYPENAME=elteresek,elteresek2&amp;Filter=%28%3Cogc:Filter%20xmlns:ogc=%22http://www.opengis.net/ogc%22%3E%3Cogc:BBOX%3E%3Cogc:PropertyName%3EmsGeometry%3C/ogc:PropertyName%3E%3Cgml:Envelope%20xmlns:gml=%22http://www.opengis.net/gml%22%20srsName=%22EPSG:23700%22%3E%3Cgml:lowerCorner%3E649971.6696%20236508.4728%3C/gml:lowerCorner%3E%3Cgml:upperCorner%3E651559.1688%20237919.5832%3C/gml:upperCorner%3E%3C/gml:Envelope%3E%3C/ogc:BBOX%3E%3C/ogc:Filter%3E%29%28%3Cogc:Filter%20xmlns:ogc=%22http://www.opengis.net/ogc%22%3E%3Cogc:BBOX%3E%3Cogc:PropertyName%3EmsGeometry%3C/ogc:PropertyName%3E%3Cgml:Envelope%20xmlns:gml=%22http://www.opengis.net/gml%22%20srsName=%22EPSG:23700%22%3E%3Cgml:lowerCorner%3E649971.6696%20236508.4728%3C/gml:lowerCorner%3E%3Cgml:upperCorner%3E651559.1688%20237919.5832%3C/gml:upperCorner%3E%3C/gml:Envelope%3E%3C/ogc:BBOX%3E%3C/ogc:Filter%3E%29</a>
      <br>
      <br>
Attila BER&Eacute;NYI wrote:
      <br>
      <blockquote type="cite">Thank you guys, I've tried with comma and
brackets as well, no success so far :(
        <br>
        <br>
2010.04.06. 14:46 keltez&eacute;ssel, Yewondwossen Assefa &iacute;rta:
        <br>
        <blockquote type="cite"><a class="moz-txt-link-abbreviated" href="mailto:bartvde@osgis.nl">bartvde@osgis.nl</a> wrote:
          <br>
          <blockquote type="cite">Hi,
            <br>
            <br>
you need to repeat your filter (comma-separated) IIRC.
            <br>
            <br>
          </blockquote>
I believe it should be brackets instead of comma: something like
...&amp;FILTER=(&lt;Filter&gt;...&lt;/Filter&gt;)(&lt;Filter&gt;...&lt;/Filter&gt;)
          <br>
          <blockquote type="cite">Best regards,
            <br>
Bart
            <br>
            <br>
            <blockquote type="cite">Dear All,
              <br>
              <br>
I've two layers (elteresek and elteresek2), and I'd like to get
features
              <br>
from both of them using WFS GetFeature request.
              <br>
If I apply one typename at a time, it works correct, but if I include
              <br>
two typenames in the request only the first is processed and included
in
              <br>
the response.
              <br>
This works correct (note TYPENAME=elteresek):
              <br>
<a class="moz-txt-link-freetext" href="http://webgis.fmt.bme.hu/cgi-bin/mvmNew?SERVICE=WFS&amp;VERSION=1.1.0&amp;REQUEST=GetFeature&amp;TYPENAME=elteresek&amp;Filter=">http://webgis.fmt.bme.hu/cgi-bin/mvmNew?SERVICE=WFS&amp;VERSION=1.1.0&amp;REQUEST=GetFeature&amp;TYPENAME=elteresek&amp;Filter=</a>&lt;ogc:Filter
              <br>
xmlns:ogc=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/ogc">"http://www.opengis.net/ogc"</a>&gt;&lt;ogc:BBOX&gt;&lt;ogc:PropertyName&gt;msGeometry&lt;/ogc:PropertyName&gt;&lt;gml:Envelope
              <br>
xmlns:gml=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/gml">"http://www.opengis.net/gml"</a>
              <br>
srsName="EPSG:23700"&gt;&lt;gml:lowerCorner&gt;649971.6696
              <br>
236508.4728&lt;/gml:lowerCorner&gt;&lt;gml:upperCorner&gt;651559.1688
              <br>
237919.5832&lt;/gml:upperCorner&gt;&lt;/gml:Envelope&gt;&lt;/ogc:BBOX&gt;&lt;/ogc:Filter&gt;
              <br>
              <br>
This works correct (note TYPENAME=elteresek2) as well:
              <br>
<a class="moz-txt-link-freetext" href="http://webgis.fmt.bme.hu/cgi-bin/mvmNew?SERVICE=WFS&amp;VERSION=1.1.0&amp;REQUEST=GetFeature&amp;TYPENAME=elteresek2&amp;Filter=">http://webgis.fmt.bme.hu/cgi-bin/mvmNew?SERVICE=WFS&amp;VERSION=1.1.0&amp;REQUEST=GetFeature&amp;TYPENAME=elteresek2&amp;Filter=</a>&lt;ogc:Filter
              <br>
xmlns:ogc=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/ogc">"http://www.opengis.net/ogc"</a>&gt;&lt;ogc:BBOX&gt;&lt;ogc:PropertyName&gt;msGeometry&lt;/ogc:PropertyName&gt;&lt;gml:Envelope
              <br>
xmlns:gml=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/gml">"http://www.opengis.net/gml"</a>
              <br>
srsName="EPSG:23700"&gt;&lt;gml:lowerCorner&gt;649971.6696
              <br>
236508.4728&lt;/gml:lowerCorner&gt;&lt;gml:upperCorner&gt;651559.1688
              <br>
237919.5832&lt;/gml:upperCorner&gt;&lt;/gml:Envelope&gt;&lt;/ogc:BBOX&gt;&lt;/ogc:Filter&gt;
              <br>
              <br>
But the reply for this link includes only the first typename (in this
              <br>
case elteresek):
              <br>
<a class="moz-txt-link-freetext" href="http://webgis.fmt.bme.hu/cgi-bin/mvmNew?SERVICE=WFS&amp;VERSION=1.1.0&amp;REQUEST=GetFeature&amp;TYPENAME=elteresek,elteresek2&amp;Filter=">http://webgis.fmt.bme.hu/cgi-bin/mvmNew?SERVICE=WFS&amp;VERSION=1.1.0&amp;REQUEST=GetFeature&amp;TYPENAME=elteresek,elteresek2&amp;Filter=</a>&lt;ogc:Filter
              <br>
xmlns:ogc=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/ogc">"http://www.opengis.net/ogc"</a>&gt;&lt;ogc:BBOX&gt;&lt;ogc:PropertyName&gt;msGeometry&lt;/ogc:PropertyName&gt;&lt;gml:Envelope
              <br>
xmlns:gml=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/gml">"http://www.opengis.net/gml"</a>
              <br>
srsName="EPSG:23700"&gt;&lt;gml:lowerCorner&gt;649971.6696
              <br>
236508.4728&lt;/gml:lowerCorner&gt;&lt;gml:upperCorner&gt;651559.1688
              <br>
237919.5832&lt;/gml:upperCorner&gt;&lt;/gml:Envelope&gt;&lt;/ogc:BBOX&gt;&lt;/ogc:Filter&gt;
              <br>
              <br>
What am I doing wrong?
              <br>
              <br>
Thanks,
              <br>
              <br>
Attila
              <br>
_______________________________________________
              <br>
mapserver-users mailing list
              <br>
<a class="moz-txt-link-abbreviated" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a>
              <br>
<a class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/mapserver-users">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a>
              <br>
              <br>
            </blockquote>
            <br>
            <br>
_______________________________________________
            <br>
mapserver-users mailing list
            <br>
<a class="moz-txt-link-abbreviated" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a>
            <br>
<a class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/mapserver-users">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a>
            <br>
            <br>
          </blockquote>
          <br>
          <br>
        </blockquote>
        <br>
      </blockquote>
      <br>
      <br>
    </blockquote>
  </blockquote>
  <br>
  <br>
</blockquote>
</body>
</html>