Skip to content
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

Domain types unsupported #97

Open
Limess opened this issue Jul 19, 2020 · 0 comments · May be fixed by #98
Open

Domain types unsupported #97

Limess opened this issue Jul 19, 2020 · 0 comments · May be fixed by #98

Comments

@Limess
Copy link

Limess commented Jul 19, 2020

Catalog domain types correctly

This would result in no additional catalog modifications are required after discovery for domain types prior to running Singer. Currently we get errors if a primary key is a domain type as it's automatically excluded.

There seems to be a line of SQL commented out above the system information query which would handle this use case, based on the postgres documentation, but I can't see any reference to why it is excluded?

https://github.com/singer-io/tap-postgres/blob/e990e88e4c41720e982c49f77dee8fc6149124de/tap_postgres/__init__.py

Expected

The type of a domain type is catalogued as the underlying data type, e.g if I create a domain as such

CREATE DOMAIN posint AS integer CHECK (VALUE > 0);
CREATE TABLE mytable (id posint);

Then the type of the posint column would be integer, rather than posint.

Actual

Domain types are catalogued with their type as the domain name, rather than the underyling data type.

This type is then marked as unsupported and excluded by default, even if the column is a primary key with a supported underlying data type.

Limess added a commit to Limess/tap-postgres that referenced this issue Jul 19, 2020
Limess added a commit to Limess/tap-postgres that referenced this issue Jul 20, 2020
Type domain types as their underlying type.

Closes singer-io#97.
@Limess Limess linked a pull request Jul 20, 2020 that will close this issue
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant