ETLMCPData Conveyance Works
Log in Start free
Guides

Full history vs range replace deliveries

Which etlmcp destinations get the whole stored history on every run, which replace only the run's dates, and why neither misses a restated day.

etlmcp delivers a run in one of two ways, and the destination decides which. A CSV export receives the full stored history of the source on every run, and Google Sheets will do the same when that destination is available. PostgreSQL replaces only the run's date range in your table, and BigQuery will do the same when it is available. Neither way works like an incremental cursor that only asks for records newer than the last one it saw, so a day an ad platform corrects after the fact still reaches you, as long as the correction falls inside the days the sync pulls again.

The two delivery modes side by side

Full history Range replace
Destinations CSV export; Google Sheets (coming) PostgreSQL; BigQuery (coming)
What one run sends Every row etlmcp holds for the source, after your rules Only the rows dated inside the run's range
What happens to earlier data A new file (CSV), or the pipeline's tab rewritten (Sheets, when available) The pipeline's own rows for those dates are deleted, then the new rows are inserted
How far back the data reaches Your plan's history Whatever the table has accumulated, plus each run's range
A run that fetched but failed to deliver Caught up by the next run, which sends everything anyway Not counted as covered: the next scheduled sync reaches back for the missed days

The webhook is a third case: it receives the run's range like PostgreSQL, but etlmcp cannot delete anything on your side, so your receiver has to replace a day's rows itself. See the webhook destination.

Why this is not an incremental cursor

An incremental sync tracks a cursor: a field such as an updated-at timestamp, where the tool remembers the highest value it has copied and next time asks only for records past it. Airbyte's page on incremental append and dedupe explains that a record changed without its cursor field moving is not picked up by the next sync. Ad reporting is exactly that case. When a platform credits a late conversion to last Tuesday, the row's key is still last Tuesday's date, so a cursor on date has already moved past it and the correction is never copied unless someone pulls that window again.

etlmcp does not keep a cursor. Every routine sync pulls a fixed window of recent days again, ending today: 7 days by default and longer for platforms whose figures keep moving, such as 29 days for Meta and 31 days for Google Ads. The fetched rows replace that source's stored rows for the same dates in one step, so the store always holds the latest figures for every day in the window. The trailing window lists every platform's number.

What happens next depends on the delivery mode, and both carry the correction forward:

  • Full history. The run reads the whole store, so last Tuesday's updated figures are in the new file next to every other day.
  • Range replace. Last Tuesday is inside the run's range, so its old rows are deleted from your table and the restated ones go in.

A correction that lands on a day older than the window is not pulled by a routine sync. If you know older days changed, run a backfill over those dates. In a full-history destination the backfilled days show up in the next file; in a range destination the backfill replaces them directly.

Choosing between them

Pick a full-history destination when you want a self-contained snapshot. Each CSV file is complete on its own, so you can open the latest one and ignore the rest. The file name carries the run's start and end dates, but the contents are the whole stored history, not only those dates. The history is capped by your plan, and days older than that are removed from the store; see how much history each plan keeps.

Two costs come with full history. The file grows with every day the store holds, and a source with a large history can have its run put off while other large syncs finish; large-history deferral explains when.

Pick a range destination when you query the data from a BI tool or SQL and want one table that grows over time. Each run touches only the dates it covers, so the work per run stays small however long your history gets. Days that age out of etlmcp's own store are not deleted from your PostgreSQL table, because no later run's range includes them. Every row carries the ID of the pipeline that wrote it in _etlmcp_pipeline_id, and a run only deletes its own pipeline's rows, so several pipelines can share one table. See how PostgreSQL rows are replaced.

If your rules drop the date column, a range destination has no dates to replace, so each run replaces all of that pipeline's rows instead.

Checking a range table after a restatement

To confirm a re-pulled day was replaced rather than added to, compare recent daily totals with the platform's own report. In PostgreSQL, with your table named ad_spend:

SELECT date, sum(cost) AS cost, sum(conversions) AS conversions, count(*) AS rows
FROM ad_spend
WHERE _etlmcp_pipeline_id = 'your pipeline id'
GROUP BY date
ORDER BY date DESC
LIMIT 14;

A day that the platform restated shows the new totals after the next sync, with no doubled row count. If your BI tool caches or refreshes incrementally on its own, make sure its refresh covers at least the days etlmcp re-pulls; the Power BI incremental refresh guide shows how for Power BI.

Related

Sources

  1. Incremental Sync - Append + Deduped — docs.airbyte.com, checked