Rune Aasgaard ( 
https://osgeo-org.atlassian.net/secure/ViewProfile.jspa?accountId=5a4ce13ad24cde298725db72
 ) *created* an issue

GeoServer ( 
https://osgeo-org.atlassian.net/browse/GEOS?atlOrigin=eyJpIjoiOGViYjgyMGNlOWI2NDU0Yjk4N2MyNGNjNDk3YjZlZmYiLCJwIjoiaiJ9
 ) / Bug ( 
https://osgeo-org.atlassian.net/browse/GEOS-10776?atlOrigin=eyJpIjoiOGViYjgyMGNlOWI2NDU0Yjk4N2MyNGNjNDk3YjZlZmYiLCJwIjoiaiJ9
 ) GEOS-10776 ( 
https://osgeo-org.atlassian.net/browse/GEOS-10776?atlOrigin=eyJpIjoiOGViYjgyMGNlOWI2NDU0Yjk4N2MyNGNjNDk3YjZlZmYiLCJwIjoiaiJ9
 ) Honoring "Customize Attributes" in choice of correct geometry column in WFS 
requests to PostGIS ( 
https://osgeo-org.atlassian.net/browse/GEOS-10776?atlOrigin=eyJpIjoiOGViYjgyMGNlOWI2NDU0Yjk4N2MyNGNjNDk3YjZlZmYiLCJwIjoiaiJ9
 )

Issue Type: Bug Assignee: Unassigned Created: 08/Dec/22 12:13 PM Priority: 
Medium Reporter: Rune Aasgaard ( 
https://osgeo-org.atlassian.net/secure/ViewProfile.jspa?accountId=5a4ce13ad24cde298725db72
 )

When using a table with several geometry columns as a data source it is 
possible to use “Customize attributes” in the Layer dialog panel to restrict 
geoserver to use only one of them. This works well for WMS layers, but not for 
WFS layers.

The following SQL examples were extracted from geoserver in “VERBOSE” logging 
mode. Only the column “geometry” was selected in “Customize attributes”. In 
both cases the correct geometry column (“geometry“) was selected for the result 
set, but in the request for the WFS server the wrong geometry column 
(“solid_geometry“) was used for the BBOX search, but this is done correctly for 
the WMS request.

This is the database request from the WFS, using the wrong geometry column for 
BBOX filtering:

SELECT "id" , "gmlid_codespace" , "is_triangulated" , "cityobject_id" , 
"parent_id" , "is_reverse" , "is_composite" , "root_id" ,encode(ST_AsEWKB( 
"geometry" ), 'base64' ) as "geometry" , "is_solid" , "gmlid" , "is_xlink" 
FROM "bygg_norge_2022_10_20". "surface_geometry" 
WHERE 
"solid_geometry" && ST_GeomFromText( 'POLYGON ((269800 7041800, 269800 7042000, 
270000 7042000, 270000 7041800, 269800 7041800))' , 0) 
AND 
ST_Intersects( "solid_geometry" , ST_GeomFromText( 'POLYGON ((269800 7041800, 
269800 7042000, 270000 7042000, 270000 7041800, 269800 7041800))' , 0)) 
LIMIT 1000000

This is the database request from the WMS using the correct geometry column for 
BBOX filtering:

SELECT "id",encode(ST_AsBinary(ST_Force2D("geometry")), 'base64') as "geometry" 
FROM "bygg_norge_2022_10_20"."surface_geometry" 
WHERE 
"geometry" && ST_GeomFromText('POLYGON ((269798.4 7041798.4, 269798.4 
7042001.6, 270001.6 7042001.6, 270001.6 7041798.4, 269798.4 7041798.4))', 
25833) 
AND 
ST_Intersects("geometry", ST_GeomFromText('POLYGON ((269798.4 7041798.4, 
269798.4 7042001.6, 270001.6 7042001.6, 270001.6 7041798.4, 269798.4 
7041798.4))', 25833))

Is it possible to make the BBOX filtering for the WFS behave like for the WMS?

( 
https://osgeo-org.atlassian.net/browse/GEOS-10776#add-comment?atlOrigin=eyJpIjoiOGViYjgyMGNlOWI2NDU0Yjk4N2MyNGNjNDk3YjZlZmYiLCJwIjoiaiJ9
 ) Add Comment ( 
https://osgeo-org.atlassian.net/browse/GEOS-10776#add-comment?atlOrigin=eyJpIjoiOGViYjgyMGNlOWI2NDU0Yjk4N2MyNGNjNDk3YjZlZmYiLCJwIjoiaiJ9
 )

Get Jira notifications on your phone! Download the Jira Cloud app for Android ( 
https://play.google.com/store/apps/details?id=com.atlassian.android.jira.core&referrer=utm_source%3DNotificationLink%26utm_medium%3DEmail
 ) or iOS ( 
https://itunes.apple.com/app/apple-store/id1006972087?pt=696495&ct=EmailNotificationLink&mt=8
 ) This message was sent by Atlassian Jira (v1001.0.0-SNAPSHOT#100212- 
sha1:8cdcfbb )
_______________________________________________
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

Reply via email to