-
Notifications
You must be signed in to change notification settings - Fork 21
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
Specify custom (non-default) schemas for streams? #163
Comments
@bdewilde clarified that what he wants here is to be able to push all data from a tap like tap-mysql to one schema. Right now the target stripes the |
Code from the SDK that does this is here https://github.com/meltano/sdk/blob/main/singer_sdk/sinks/sql.py#L73-L81 |
Requested in Slack: https://meltano.slack.com/archives/C01TCRBBJD7/p1699541259229359 |
Indeed that would be great. We have around 800 tables in our backend DB (spread over 10 to 15 schemas) and being able to map Right now, our workaround is to split the tap in several sub-taps, all needing to be individually scheduled - it's a pain, but I didn't find a better way. Toy example: plugins:
extractors:
- name: tap-postgres--prod
inherit_from: tap-postgres
config:
host: xx
port: 5432
database: xx
load_schema: backend
select:
- "*.*"
# Ignored tables
- "!public-activity.*"
- "!public-pg_*.*"
# Ignored schemas
- "!auth-*.*"
- "!misc-*.*"
metadata:
"*":
replication-method: LOG_BASED
- name: tap-postgres--prod-auth
inherit_from: tap-postgres--prod
load_schema: backend_auth
select:
- "auth-*.*"
metadata:
"*":
replication-method: LOG_BASED
- name: tap-postgres--prod-misc
inherit_from: tap-postgres--prod
load_schema: backend_misc
select:
- "misc-*.*"
metadata:
"*":
replication-method: LOG_BASED |
I'm currently using the "transferwise" target-postgres variant's
schema_mapping
setting to load data from different source dbs into their own schemas. This has been useful to keep data well-organized in the target postgres db.I'm interested in switching to this variant, but don't see this option mentioned in the docs or in plans for future support. Would it be possible to add this functionality?
The text was updated successfully, but these errors were encountered: