Join Slack
Communities
Powered by
Hi All, why are there no primary key constraints p...
# contributing-to-airbyte
v
Vijay
11/04/2021, 9:51 PM
Hi All, why are there no primary key constraints placed in Airbyte generated final tables? even when primary keys are specified in the connection setting? if they are not in the table, how is Airbyte deduplicating? I see it is indeed deduplicating.
Vijay
11/05/2021, 2:01 AM
Hello Vijay! There is an issue opened requesting this feature:
https://github.com/airbytehq/airbyte/issues/6161
u
user
11/05/2021, 4:16 AM
thanks
@[DEPRECATED] Marcos Marx
u
user
11/05/2021, 5:49 PM
With versions 0.30.25+, incremental normalization is also outputting INDEX directives when creating the tables in Postgres. It’s also specifying the `unique_key`but dbt doesn’t “materialize” it as a real primary key in postgres… see example:
https://github.com/airbytehq/airbyte/blob/master/airbyte-integrations/bases/base-n[…]/airbyte_incremental/test_normalization/dedup_exchange_rate.sql
and dbt docs: •
https://docs.getdbt.com/reference/resource-configs/unique_key
•
https://docs.getdbt.com/reference/resource-configs/postgres-configs
Open in Slack
Previous
Next