[Spanish] Descargar geojson aplicando filtro a WFS

samuelmesa at gmail.com samuelmesa at gmail.com
Thu Nov 20 08:27:23 PST 2014


Realmente no es necesario este parámetro, sólo si quiere devolver el número
de elementos que coinciden con el filtro, claro, sin traerse los elementos
con tributos y geometrías.

El 20 de noviembre de 2014, 11:16, Javier Diaz <javidiaz1977 at gmail.com>
escribió:

> Nuevamente gracias. Lo probe y me funciono asi:
>
>
> http://sig.gobierno.gba.gov.ar/geoserver/arba/ows?service=WFS&version=1.1.0&request=GetFeature&typeName=arba:parcelas&maxFeatures=1&outputFormat=application/json&Filter=
> <Filter><PropertyIsEqualTo><PropertyName>partido</PropertyName><Literal>130</Literal></PropertyIsEqualTo></Filter>
>
> Use como indicaste la version 1.10
>
> Pero al agregar: &resultType=Hits. Me da el siguiente error:
>
> <wfs:FeatureCollection numberOfFeatures="1"
> timeStamp="2014-11-20T13:14:39.575Z"
> xsi:schemaLocation="http://www.opengis.net/wfs
> http://schemas.opengis.net/wfs/1.1.0/wfs.xsd"/>
>
>
> Javier
>
> El día 20 de noviembre de 2014, 13:03, Javier Diaz
> <javidiaz1977 at gmail.com> escribió:
> > Muchisimas gracias Samuel.
> > Justamente por lo que dices estoy aplicando la propiedad maxFeatures=1
> > para ver una sola parcela y evitar las 71331 :P. Hasta ver si
> > funciona.
> > Lo pruebo y te comento.
> >
> > El día 20 de noviembre de 2014, 12:58, samuelmesa at gmail.com
> > <samuelmesa at gmail.com> escribió:
> >> Saludos Javier, creo que debes usar el parámetro de FILTER para filtrar
> por
> >> un atributo o espacialmente, no sé si funcione esto:
> >>
> >>
> http://sig.gobierno.gba.gov.ar/geoserver/arba/ows?service=WFS&version=1.1.0&request=GetFeature&typeName=arba:parcelas&outputFormat=application/json&Filter=
> <Filter><PropertyIsEqualTo><PropertyName>partido</PropertyName><Literal>130</Literal></PropertyIsEqualTo></Filter>&resultType=Hits
> >>
> >> Según observo no existe ningún atributo NOMBRE en la capa parcelas, así
> que
> >> creo que un ejemplo podría ser PARTIDO=130.
> >>
> >> Esta consulta por partido=130 trae cerca de 71331 lo que llevaría algo
> de
> >> tiempo para su representación, para obtener el JSON elimina el parámetro
> >> resultType=Hits.  Ten en cuenta usar la versión 1.1.0 del servicio WFS.
> >>
> >> Más documentación en Mapserver sobre filtros en:
> >> http://mapserver.org/ogc/filter_encoding.html
> >>
> >> Cordialmente,
> >>
> >> Samuel Mesa
> >>
> >> 2014-11-20 9:54 GMT-05:00 Javier Diaz <javidiaz1977 at gmail.com>:
> >>>
> >>> Buen dia Lista.
> >>> Estoy visualizando via web este geojson:
> >>>
> >>>
> >>>
> {"type":"FeatureCollection","totalFeatures":5584311,"features":[{"type":"Feature","id":"parcelas.5356661","geometry":{"type":"MultiPolygon","coordinates":[[[[5616116.59,6180969.26],[5616108.21,6180963.93],[5616102.63,6180972.68],[5616134.42,6180992.65],[5616139.96,6180983.84],[5616116.59,6180969.26]]]]},"geometry_name":"the_geom","properties":{"nomencla":"132040V00000000000000000000000210000008000","partido":132,"etiqueta":"8","rural":false,"partida":61572,"caracteris":"2"}}],"crs":{"type":"EPSG","properties":{"code":"22185"}}}
> >>>
> >>> estoy aplicando la propiedad maxFeatures=1 en la URL del servicio (1).
> >>>
> >>> Mi duda es como puedo aplicar un filtro usando el valor nombre=
> >>> partido:130?
> >>>
> >>> Saludos
> >>> Javier
> >>>
> >>> (1)
> >>>
> http://sig.gobierno.gba.gov.ar/geoserver/arba/ows?service=WFS&version=1.0.0&request=GetFeature&typeName=arba:parcelas&maxFeatures=1&outputFormat=application/json
> >>> _______________________________________________
> >>> Spanish mailing list
> >>> http://lists.osgeo.org/mailman/listinfo/spanish
> >>> http://es.osgeo.org
> >>> http://twitter.com/osgeoes
> >>
> >>
> >>
> >>
> >> --
> >> ---
> >>     .~.
> >>    / v \
> >>   //    \\
> >>  /(      )\
> >>    ^`~'^
> >>
> >> _______________________________________________
> >> Spanish mailing list
> >> http://lists.osgeo.org/mailman/listinfo/spanish
> >> http://es.osgeo.org
> >> http://twitter.com/osgeoes
> _______________________________________________
> Spanish mailing list
> http://lists.osgeo.org/mailman/listinfo/spanish
> http://es.osgeo.org
> http://twitter.com/osgeoes
>



-- 
---
    .~.
   / v \
  //    \\
 /(      )\
   ^`~'^
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/spanish/attachments/20141120/608d25a2/attachment-0001.html>


More information about the Spanish mailing list