How do you test territory alignment and incentive compensation data before payout?

Test alignment as a relationship, not a column. Before the comp run, confirm every prescriber resolves to one master record, every zip and territory exists in the current hierarchy, territory totals still tie to the national total, and activity and sales use the same alignment version. Column checks pass all four failures.

Key points

  • A territory realignment can drop a rep's numbers 40 percent overnight while the underlying data stays correct, so alignment has to be tested as a relationship between feed and mapping.
  • A duplicated prescriber splits credit across two records and the incentive comp run pays the wrong reps. Nobody notices until the comp run, and then everybody notices.
  • Aggregate Balance confirms territory rollups still tie to their detail, so a realignment moves credit between territories without changing the national total.
  • Field activity and field performance computed against different alignment versions never reconcile. Once activity and performance are joined, that is a Custom Condition; before the join, a Reference Match on the alignment version catches it.
  • Every test result in TestGen takes a disposition, which leaves the record you need when a rep disputes their comp.

The comp run is where a data problem stops being hypothetical. The rep calls. Then their manager calls. And the number they are disputing is tied to a paycheck.

Most of what breaks incentive compensation isn’t bad data in the usual sense. The data sources reference puts it plainly: a realignment drops a rep 40 percent overnight while the underlying data stays perfectly correct. A duplicated prescriber splits credit across two records, and nobody notices until the comp run, and then everybody notices.

Both failures pass every null check, format check, and row count you have.

The failures are relational

A column test asks whether a value is present and well formed. Alignment errors are failures of the relationship between tables: a territory ID in the roster that doesn’t exist in the hierarchy, or an account with sales activity that never made it into the account master. Every individual value is valid. The join is what’s wrong.

Alignment also changes on a schedule you don’t control. The quarterly Veeva alignment load is one of the recurring jobs that eats commercial data hours. Our own data sources reference says the roster arrives “periodically, and always at the worst moment.”

Six checks to run before the comp period closes

CheckWhat it catchesTestGen test
Every prescriber key in the IC credit table appears once in the masterA duplicated prescriber splitting creditDuplicate Rows, Unique Values
Every zip and territory in the roster exists in the current hierarchyOrphaned territories that drop sales from the roll-upReference Match
Territory totals tie to national totals, per groupingIntegration steps dropping or double-counting rowsAggregate Balance
National total matches the prior delivery after a realignmentTelling a mapping change from a data changeAggregate Balance against the prior delivery
Activity and performance use the same alignment versionField reports that never reconcileCustom Condition on the joined data, or Reference Match on the alignment version
Every target resolves to a current master recordCall plans pointing at prescribers who no longer existReference Match

Most compare one table against another, or one delivery against the last. That is the point.

The fourth row settles the 40 percent call. Did the national total hold while the rep’s territory dropped? Then the mapping moved the credit. That is a sales operations conversation, not a data defect, and you can have it with evidence the same morning. If the national total moved too, something upstream changed, and the comp run waits.

The fifth row comes straight from the field performance report, which breaks under a realignment while every underlying value stays valid, and from field activity and performance being computed against different alignment versions. Once activity and performance are joined, a Custom Condition expresses that rule as one condition instead of a custom SQL query. If they live in separate tables, a Reference Match on the alignment version does the same job.

Run the identifier tests underneath all six. A transposed NPI drops a prescriber from the join while a pattern check stays green, and in the illustrative ticket from our identifier post, a rep’s territory comes up about 40 TRx short because of it.

Keep the record

The IC quota and grade inputs arrive weekly or by comp period. Whatever the cadence, the test results are your answer to a dispute. In DataOps TestGen every result takes a disposition: confirm it as a real problem, dismiss it as reviewed, or mute a known issue. That durable record of tests, results, and dispositions is what lets you show the number held.

Where the IC system fits

The IC system and the alignment design belong to sales operations and whichever vendor runs them. What they read is the data layer. That is what you test. On one launch behind a multi-billion-dollar acquisition, the incentive compensation system computed reward structures from data in Snowflake that DataKitchen software had transformed and quality checked, and IC reports were ready before launch along with field reporting.

The comp run is the wrong place to find out the alignment changed.

Frequently asked questions

Short answers to the follow-up questions people ask next.

Why did a rep's numbers drop 40 percent after a realignment?

Because the mapping changed, not the sales. A realignment moves zips and accounts between territories, and a rep's TRx can fall 40 percent overnight while nothing in the file is invalid. Test the national total against the prior delivery and the territory totals against their detail; if the nation holds and territories move, the mapping did it.

How does a duplicate prescriber affect incentive comp?

It splits credit across two records, and the comp run pays the wrong reps. A duplicate usually comes from two prescriber sources that disagree, such as IQVIA showing one Dr. Smith and the master showing two. Run Duplicate Rows and Unique Values checks on the prescriber key in the IC credit table before every comp period closes.

Can column-level data quality checks catch alignment errors?

No. Alignment errors are relational. A territory ID in the roster that does not exist in the hierarchy, or an account with sales that never made it into the account master, carries valid values in every column. Only a test that compares one table against another, such as TestGen's Reference Match, sees the broken relationship.

How do you defend an incentive comp number when a rep disputes it?

Show the check that passed. When every test result on the IC inputs carries a disposition (confirmed, dismissed as reviewed, or muted as a known issue) you have a durable record of what was tested and what was found for that comp period. A reconciliation trail turns "trust me" into "here is the check that passed."

Does DataKitchen run incentive compensation?

No. DataKitchen does not do incentive compensation, territory alignment, or call planning. It builds and tests the commercial data layer those systems read. On one launch, the IC system computed rewards from data in Snowflake that DataKitchen software had transformed and quality checked, and IC reports were ready before launch.

Talk to the people who test this data every week

DataKitchen builds and runs commercial data platforms for small and midsize pharma, with the tests in place from day one.