Skip to content

Conversation

@fivetran-data-model-bot
Copy link
Contributor

Summary

This PR is to combine the source and transform packages and remove tests not compatible with dbt Fusion 1.10.6+.

Please check the below automated updates were successful:

Source + Transform Consolidation

  • Merged dbt_linkedin_source into this transformation package.
  • Moved models/macros to models/staging/ and macros/staging/.
  • Updated all var('') references to use ref('stg_linkedin__').
  • Removed the source package from packages.yml.
  • Updated vars in dbt_project.yml from refs to sources.
  • Major version bump to v1.0.0

dbt Fusion Compatibility

  • Removed dbt_utils.unique_combination_of_columns test
  • Accepted values tests were removed where applicable (Shopify, NetSuite, QuickBooks).

YAML & Config Updates

  • Moved loaded_at_field under config: in src.yml, grouped with freshness
  • Added +schema and +materialization for the staging models in dbt_project.yml.

README

  • Removed references to the source package in:
    • Overview
    • Installation instructions
    • Dependencies list
    • Schema override examples

@fivetran-data-model-bot fivetran-data-model-bot added the next-release Include in the next release. label Aug 12, 2025
Copy link
Contributor

@fivetran-jamie fivetran-jamie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks awesome!!!! Left suggestions/comments for the changelog generation

[PR #50](https://github.com/fivetran/dbt_linkedin/pull/50) includes the following updates:

## Breaking Changes
> A `--full-refresh` is required after upgrading to this release.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will this actually be necessary for incremental models?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

True--probably not necessary.

### Source Package Consolidation
- Consolidated `dbt_linkedin_source` into this package.
- All functionality from the source package has been merged into this transformation package. Be sure to:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

People will also need to adjust any linkedin_source-scoped configs in their dbt_project.yml, either to be scoped to just linkedin or to the staging subfolder

- Consolidated `dbt_linkedin_source` into this package.
- All functionality from the source package has been merged into this transformation package. Be sure to:
- Remove `fivetran/linkedin_source` from `packages.yml`
- Delete any `source:` overrides that reference the source package
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If they are still on a dbt version that supports overrides, they can update the overrides: config to be overrides: linkedin instead of overrides: linkedin_source

Comment on lines +15 to +16
- Removed `dbt_utils.unique_combination_of_columns` tests
- Removed `accepted_values` tests
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we say that we'll likely add these back in in the future once more users are upgraded?

version: [">=1.0.0", "<1.1.0"]
```
Do **NOT** include the `linkedin_source` package in this file. The transformation package itself has a dependency on it and will install the source package as well.
> All required sources are now bundled into this transformation package. Do not include `fivetran/linkedin_source` in your `packages.yml`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
> All required sources are now bundled into this transformation package. Do not include `fivetran/linkedin_source` in your `packages.yml`.
> All required sources and staging models are now bundled into this transformation package. Do not include `fivetran/linkedin_source` in your `packages.yml`, as this package has been deprecated.

Maybe

Comment on lines +7 to +15
ad_analytics_by_creative: "{{ source('linkedin_ads', 'ad_analytics_by_creative') }}"
creative_history: "{{ source('linkedin_ads', 'creative_history') }}"
campaign_history: "{{ source('linkedin_ads', 'campaign_history') }}"
campaign_group_history: "{{ source('linkedin_ads', 'campaign_group_history') }}"
account_history: "{{ source('linkedin_ads', 'account_history') }}"
ad_analytics_by_campaign: "{{ source('linkedin_ads', 'ad_analytics_by_campaign') }}"
geo: "{{ source('linkedin_ads', 'geo') }}"
monthly_ad_analytics_by_member_country: "{{ source('linkedin_ads', 'monthly_ad_analytics_by_country') }}"
monthly_ad_analytics_by_member_region: "{{ source('linkedin_ads', 'monthly_ad_analytics_by_region') }}"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we call out this change in the CHANGELOG in case people were utilizing the variables?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes

+materialized: table
+schema: linkedin_ads
staging:
+schema: linkedin_source
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
+schema: linkedin_source
+schema: linkedin_ads_source

* Q2 FY26: Apply automated update.

* Q2 FY26: Update auto-release workflow only.

* Update CHANGELOG.md

---------

Co-authored-by: fivetran-catfritz <111930712+fivetran-catfritz@users.noreply.github.com>
Co-authored-by: Joe Markiewicz <74217849+fivetran-joemarkiewicz@users.noreply.github.com>
Copy link
Contributor

@fivetran-avinash fivetran-avinash Aug 12, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if we need to add a staging sub-folder for macros since they're all functions being applied across models. They could all live in the macros folder I think. Also avoids us having to move it in the future in case we were to apply a macro like date_from_month_string beyond the staging layer.

Copy link
Contributor

@fivetran-catfritz fivetran-catfritz Aug 12, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No it's not necessary, but I opted to do this to keep them separated for now since the staging macros can get a bit much. Being in a sub folder should not restrict them to be used by only the staging models. Kind of like how we put the dbt date macros in their own folder.


## What does this dbt package do?
- Produces modeled tables that leverage Linkedin Ad Analytics data from [Fivetran's connector](https://fivetran.com/docs/applications/linkedin-ads) in the format described by [this ERD](https://fivetran.com/docs/applications/linkedin-ads#schemainformation) and builds off the output of our [Linkedin Ads source package](https://github.com/fivetran/dbt_linkedin_source).
- Produces modeled tables that leverage Linkedin Ad Analytics data from [Fivetran's connector](https://fivetran.com/docs/applications/linkedin-ads) in the format described by [this ERD](https://fivetran.com/docs/applications/linkedin-ads#schemainformation).
Copy link
Contributor

@fivetran-avinash fivetran-avinash Aug 12, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You could leverage this sentence from the Workday package (already consolidated) around how the staging tables are materialized via the ERD.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We will want to update the Changing the Build Schema section to account for the new staging configuration. Example from the Workday package.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ahh yes good catch. It turns out Linkedin just got messed up because of the linkedin vs linkedin_ads issue, but the other packages will get the update!

@fivetran-catfritz
Copy link
Contributor

Thanks everyone for the comments! i'm going to close this PR so we can start fresh with the script.

@fivetran-catfritz fivetran-catfritz deleted the MagicBot/consolidate-source-package branch August 12, 2025 22:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

next-release Include in the next release.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants