Closed umartin closed 2 days ago
I'm having trouble getting the tests to pass. TestPostgreSqlPlugin fails because the geometry type is not injected into PostgreSqlClient. I couldn't figure out how to fixed that.
It looks like the TestingConnectorContext used in TestPostgreSqlPlugin doesn't have the geometry type in the type manager. TestingConnectorContext is a final class so I can't extend it. Should I just create a TestingPostgreSqlConnectorContext with an extended type manager?
@ebyhr I think this PR is ready for review. All checks pass. I've also built and tested the trino docker image with postgis manually.
Thank you for your feedback @ebyhr. I've updated the PR with all of your suggestions.
Description
Add support for geometry type mapping in the PostgreSQL connector.
Additional context and related issues
Issue: #5580 There is an old, inactive PR at #9951
My take is slightly different when it comes to reading PostGIS geometries. The previous attempt rewrote the query and wrapped geometry columns in ST_GeomAsWKB to convert them to a Well Known Binary format. I'm using the native format which is hex encoded EWKB.
Release notes