Skip to content

Refactor redshift__pit macro parameters and logic#412

Open
polat-deniz wants to merge 6 commits intomainfrom
redshift-pit-optimizing
Open

Refactor redshift__pit macro parameters and logic#412
polat-deniz wants to merge 6 commits intomainfrom
redshift-pit-optimizing

Conversation

@polat-deniz
Copy link
Collaborator

Description

Optimizing PIT performance for redshift

Fixes #(issue)

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce.

  • Tests you ran

Test Configuration:

  • datavault4dbt-Version:
  • dbt-Version: cloud/core, version number
  • dbt-adapter-Version:

Checklist:

  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation or included information that needs updates (e.g. in the Wiki)

@tkirschke
Copy link
Member

Hi @polat-deniz and thanks for the contribution!

2 remarks from my side:

  • please adjust formatting, your changes include many unneccessary new lines, this also makes it pretty hard to compare
  • the dimension key is now optional on a parameter level, but in the actual code it's not used at all. Please trigger the hash calculation from the previous code, if the parameter is actually defined.

@polat-deniz
Copy link
Collaborator Author

Hi @tkirschke,
Thank you for your remarks, you are right! I adjusted the formatting and the use of the dimension key.

@tkirschke tkirschke added the testing To trigger the automated test workflow as internal User. label Jan 29, 2026
@remoteworkflow
Copy link

dbt test combined result: ❌


Details

RESULTS for Synapse:
❌ dbt-tests
⚠️ dbt-macro-tests
⚠️ tech-tests


RESULTS for Postgres:
❌ dbt-tests
⚠️ dbt-macro-tests
⚠️ tech-tests


RESULTS for BigQuery:
❌ dbt-tests
⚠️ dbt-macro-tests
⚠️ tech-tests


RESULTS for Redshift:
❌ dbt-tests
⚠️ dbt-macro-tests
⚠️ tech-tests


RESULTS for Snowflake:
❌ dbt-tests
⚠️ dbt-macro-tests
⚠️ tech-tests


RESULTS for Exasol:
❌ dbt-tests
⚠️ dbt-macro-tests
⚠️ tech-tests


RESULTS for Fabric:
❌ dbt-tests
⚠️ dbt-macro-tests
⚠️ tech-tests


RESULTS for Oracle:
❌ dbt-tests
⚠️ dbt-macro-tests
⚠️ tech-tests


RESULTS for Databricks:
❌ dbt-tests
⚠️ dbt-macro-tests
⚠️ tech-tests


Link to workflow summary: https://github.com/ScalefreeCOM/datavault4dbt-ci-cd/actions/runs/21484961374

@remoteworkflow remoteworkflow bot removed the testing To trigger the automated test workflow as internal User. label Jan 29, 2026
@tkirschke
Copy link
Member

@polat-deniz there are some problems with the macro definition:

Compilation Error
  non-default argument follows default argument
    line 1
      {%- macro redshift__pit(tracked_entity, hashkey, sat_names, ldts, ledts, sdts, snapshot_relation, dimension_key=none, refer_to_ghost_records, snapshot_trigger_column=none, custom_rsrc=none, pit_type=none, snapshot_optimization=false) -%}

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 this pull request may close these issues.

2 participants