Skip to content

Queries using bbox-crs return different numbers of results when resulttype=hits and not, when using a CRS with y/x axis ordering #2027

@mikemahoney218-usgs

Description

@mikemahoney218-usgs

Queries using bbox-crs return different numbers of results when resulttype=hits and not, when using a CRS with y/x axis ordering:

curl https://demo.pygeoapi.io/master/collections/dutch_windmills/items?f=json&bbox=3.37,50.75,7.21,53.47&bbox-crs=http://www.opengis.net/def/crs/EPSG/0/4326
{
    "type":"FeatureCollection",
    "features":[],
    "links":[
        {
            "type":"application/geo+json",
            "rel":"self",
            "title":"This document as GeoJSON",
            "href":"https://demo.pygeoapi.io/master/collections/dutch_windmills/items?f=json&bbox=3.37,50.75,7.21,53.47&bbox-crs=http%3A%2F%2Fwww.opengis.net%2Fdef%2Fcrs%2FEPSG%2F0%2F4326"
        },
        {
            "rel":"alternate",
            "type":"application/ld+json",
            "title":"This document as RDF (JSON-LD)",
            "href":"https://demo.pygeoapi.io/master/collections/dutch_windmills/items?f=jsonld&bbox=3.37,50.75,7.21,53.47&bbox-crs=http%3A%2F%2Fwww.opengis.net%2Fdef%2Fcrs%2FEPSG%2F0%2F4326"
        },
        {
            "type":"text/html",
            "rel":"alternate",
            "title":"This document as HTML",
            "href":"https://demo.pygeoapi.io/master/collections/dutch_windmills/items?f=html&bbox=3.37,50.75,7.21,53.47&bbox-crs=http%3A%2F%2Fwww.opengis.net%2Fdef%2Fcrs%2FEPSG%2F0%2F4326"
        },
        {
            "type":"application/json",
            "title":"Windmills within The Netherlands",
            "rel":"collection",
            "href":"https://demo.pygeoapi.io/master/collections/dutch_windmills"
        }
    ],
    "timeStamp":"2025-05-09T17:08:37.672879Z"
}
curl https://demo.pygeoapi.io/master/collections/dutch_windmills/items?f=json&bbox=3.37,50.75,7.21,53.47&bbox-crs=http://www.opengis.net/def/crs/EPSG/0/4326&resulttype=hits
{
    "type":"FeatureCollection",
    "numberMatched":1872,
    "features":[],
    "links":[
        {
            "type":"application/geo+json",
            "rel":"self",
            "title":"This document as GeoJSON",
            "href":"https://demo.pygeoapi.io/master/collections/dutch_windmills/items?f=json&bbox=3.37,50.75,7.21,53.47&bbox-crs=http%3A%2F%2Fwww.opengis.net%2Fdef%2Fcrs%2FEPSG%2F0%2F4326&resulttype=hits"
        },
        {
            "rel":"alternate",
            "type":"application/ld+json",
            "title":"This document as RDF (JSON-LD)",
            "href":"https://demo.pygeoapi.io/master/collections/dutch_windmills/items?f=jsonld&bbox=3.37,50.75,7.21,53.47&bbox-crs=http%3A%2F%2Fwww.opengis.net%2Fdef%2Fcrs%2FEPSG%2F0%2F4326&resulttype=hits"
        },
        {
            "type":"text/html",
            "rel":"alternate",
            "title":"This document as HTML",
            "href":"https://demo.pygeoapi.io/master/collections/dutch_windmills/items?f=html&bbox=3.37,50.75,7.21,53.47&bbox-crs=http%3A%2F%2Fwww.opengis.net%2Fdef%2Fcrs%2FEPSG%2F0%2F4326&resulttype=hits"
        },
        {
            "type":"application/geo+json",
            "rel":"next",
            "title":"Items (next)",
            "href":"https://demo.pygeoapi.io/master/collections/dutch_windmills/items?offset=10&bbox=3.37,50.75,7.21,53.47&bbox-crs=http%3A%2F%2Fwww.opengis.net%2Fdef%2Fcrs%2FEPSG%2F0%2F4326&resulttype=hits"
        },
        {
            "type":"application/json",
            "title":"Windmills within The Netherlands",
            "rel":"collection",
            "href":"https://demo.pygeoapi.io/master/collections/dutch_windmills"
        }
    ],
    "timeStamp":"2025-05-09T17:09:10.170692Z"
}

Originally posted by @mikemahoney218-usgs in #2010

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions