[
https://issues.apache.org/jira/browse/FLINK-9219?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16474080#comment-16474080
]
Timo Walther commented on FLINK-9219:
-------------------------------------
Thanks for working on this [~xccui]. Here is some feedback:
- As mentioned earlier, I would not use the Calcite type for the type
information but {{com.esri.core.geometry.Geometry}}. I think this is the reason
why {{org.apache.calcite.runtime.GeoFunctions}} has a protected {{bind()}}
method that we can override.
- Move the GEOMETRY type information class to
{{org.apache.flink.table.typeutils}}
- I would separate the geo functions from the core as much as possible. For
example, having a seperate {{GeoFunctionsTest}} instead of
{{ScalarFunctionsTest}}.
- Maybe we should not expose all 150 functions through {{expressionDsl.scala}}.
I think it is ok to only support those special functions in SQL for now. We can
still add them to the Table API later. What do you think [~fhueske]?
- I'm wondering if we should contribute the {{new SqlFunction}} definitions
about operands and return types to Calcite. Maybe we can contribute a
{{GeoOperatorTable}} similar to
{{org.apache.calcite.sql.fun.SqlStdOperatorTable}}.
> Add support for OpenGIS features in Table & SQL API
> ---------------------------------------------------
>
> Key: FLINK-9219
> URL: https://issues.apache.org/jira/browse/FLINK-9219
> Project: Flink
> Issue Type: New Feature
> Components: Table API & SQL
> Reporter: Timo Walther
> Assignee: Xingcan Cui
> Priority: Major
>
> CALCITE-1968 added core functionality for handling
> spatial/geographical/geometry data. It should not be too hard to expose these
> features also in Flink's Table & SQL API. We would need a new {{GEOMETRY}}
> data type and connect the function APIs.
> Right now the following functions are supported by Calcite:
> {code}
> ST_AsText, ST_AsWKT, ST_Boundary, ST_Buffer, ST_Contains,
> ST_ContainsProperly, ST_Crosses, ST_Disjoint, ST_Distance, ST_DWithin,
> ST_Envelope, ST_EnvelopesIntersect, ST_Equals, ST_GeometryType,
> ST_GeometryTypeCode, ST_GeomFromText, ST_Intersects, ST_Is3D,
> ST_LineFromText, ST_MakeLine, ST_MakePoint, ST_MLineFromText,
> ST_MPointFromText, ST_MPolyFromText, ST_Overlaps, ST_Point, ST_PointFromText,
> ST_PolyFromText, ST_SetSRID, ST_Touches, ST_Transform, ST_Union, ST_Within,
> ST_Z
> {code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)