# dbt tests - compare incrimental vs a full rebuild of said model

**URL:** <https://discourse.getdbt.com/t/dbt-tests-compare-incrimental-vs-a-full-rebuild-of-said-model/20179>\
**Category:** Help\
**Tags:** testing\
**Created:** [August 22, 2025, 7:23pm UTC](https://discourse.getdbt.com/t/dbt-tests-compare-incrimental-vs-a-full-rebuild-of-said-model/20179 "2025-08-22T19:23:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jn666](https://avatars.discourse-cdn.com/v4/letter/j/67e7ee/32.png) [@Jn666](https://discourse.getdbt.com/u/Jn666)\
**Post date:** [August 22, 2025, 7:23pm UTC](https://discourse.getdbt.com/t/dbt-tests-compare-incrimental-vs-a-full-rebuild-of-said-model/20179/1 "2025-08-22T19:23:24Z")

</div>

New to dbt and loving a lot of its features particularly tests. I am replicating a lot of our tests that exists as custom SQL and moving them into dbt tests. I am having one test I am struggling. Simple put it is a test that would compare the target table with a full rebuild of the table (compare primary keys). We do this at the moment by having 2 seperate scripts that have the transformation code largely duplicated. I was hoping that with a marco I could compare the model with a full rebuild of itself. However I am getting nowhere at the moment.
