-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
INTERSECTS cql2-text with WKT polygon #200
Comments
My bad ! I find exemple in test_items.py.
but now if i but:
I have API response:
But my geography column have cast "geography": all my data is in 4326. anyone can help me ? |
I'm running into the same issue, and I believe the reason is that old versions of PostGIS - i.e., the 3.3 I'm currently using - for some reasons are unable to do implicit cast of EWKT strings to geometries, passed as argument to
So the solution seems to be to either upgrade PostGIS, if possible, or modify TiPG's filtering operators to cast to geometry explicitly through from tipg.filter.filters import Operator
Operator.OPERATORS["INTERSECTS"] = lambda f, a: Func(
"st_intersects",
f,
Func("st_transform", Func("st_geomfromewkt", a), Func("st_srid", f)),
) |
Hi,
I try to make a filter with:
or
API respond:
{ "detail": "Unexpected token Token('$END', '') at line 1, column 131.\nExpected one of: \n\t* LESSTHAN\n\t* BETWEEN\n\t* T_CONTAINS\n\t* T_DURING\n\t* T_METBY\n\t* EQ\n\t* __ANON_2\n\t* LTE\n\t* T_ENDS\n\t* GTE\n\t* T_EQUALS\n\t* T_INTERSECTS\n\t* EQUAL\n\t* __ANON_0\n\t* IN\n\t* GT\n\t* IS\n\t* T_OVERLAPS\n\t* T_BEFORE\n\t* LIKE\n\t* T_BEGUNBY\n\t* T_ENDEDBY\n\t* T_AFTER\n\t* T_BEGINS\n\t* T_MEETS\n\t* LT\n\t* T_OVERLAPPEDBY\n\t* __ANON_3\n\t* MORETHAN\n\t* NE\n\t* __ANON_1\n" }
so it's not working.
In pygeofilter it says : "Soon: [CQL Text as defined in OGC API - Features - Part 3: Filtering and the Common Query Language (CQL)]"
So we can't for the moment filter our query by ST_INTERSECT function ?
thanks in advance for your response
The text was updated successfully, but these errors were encountered: