-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Document PostgreSQL type mapping #11378
Conversation
I cant comment on technical accuracy but typically there are different mappings for read vs create table style operations. https://trino.io/docs/current/connector/oracle.html#type-mapping And we probably should also import https://trino.io/docs/current/connector/redshift.html#id1 |
The best wording that clarifies the two mappings can be found in https://docs.starburst.io/latest/connector/starburst-synapse.html#type-mapping .. we have plans to make all connectors in Trino consistent along those lines but have not gotten around to it. Maybe we can use this PR as model to establish a good baseline wording for this in Trino. |
The "General configuration properties" already exists in the PostgreSQL documentation. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some of these comments are about adding more test coverage. I'll create separate issues for those.
``BIT`` ``BOOLEAN`` | ||
``SMALLINT`` ``SMALLINT`` | ||
``INTEGER`` ``INTEGER`` | ||
``BIGINT`` ``BIGINT`` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This reminds that we should probably also test smallserial, serial and bigserial types too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
=================== ================================ ======================================================================= | ||
PostgreSQL Trino Notes | ||
=================== ================================ ======================================================================= | ||
``BIT`` ``BOOLEAN`` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PostgreSQL has a real boolean type too.
Also do we properly handle bit(n)
in the connector?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also do we properly handle bit(n) in the connector?
I don't think so.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
2f11f11
to
b21e397
Compare
ENUM is missing. We map that to a VARCHAR. There are tests for it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM % enum + time(n)
b21e397
to
f042995
Compare
Description
Document PostgreSQL type mapping
Related issues, pull requests, and links
Documentation
( ) No documentation is needed.
(x) Sufficient documentation is included in this PR.
( ) Documentation PR is available with #prnumber.
( ) Documentation issue #issuenumber is filed, and can be handled later.
Release notes
(x) No release notes entries required.
( ) Release notes entries required with the following suggested text: