Skip to content
Faisal Mahmud TusherDigital marketing, SEO & analytics
with Faisal Tusher

Marketing Data & Analytics Library › Practice Datasets

Sample Campaign Dataset

A synthetic daily campaign dataset for practice: the schema, how it was generated, a sample of rows, the questions it can answer, and exercises.
Data resourceintermediate8 min readUpdated

What this dataset is

The table imitates the export a paid media analyst works with most: a daily grain, one row per campaign, with the volume metrics the platforms report and the outcome metrics that analytics or an order system adds. It covers one quarter of activity for an invented online retailer running paid search, paid social, display and video, with several campaigns per channel. Because it is synthetic, every pattern in it is either a documented rule or documented noise, and the practice datasets hub explains why that property makes generated data the right material for learning and the wrong material for benchmarks.

The dataset pairs with the sample e-commerce dataset, which shares its channel names so that spend here can be joined to new customers there. It is small enough to open in a spreadsheet and inspect, and structured so that the patterns from the SQL for marketers guide and the calculated fields guide apply without adaptation. The metrics it supports are the ones a paid media team reports daily: cost per thousand impressions (CPM), click-through rate (CTR), cost per acquisition (CPA) and return on ad spend (ROAS).

Schema

One table, campaign_daily, with one row per campaign per day. Column names are lower case with underscores, and the date column is an ISO date so that it sorts as text and parses as a date.

ColumnTypeDescriptionNotes
dateDateThe day the activity occurredEvery campaign has a row for every day it was active, including days with zero spend
channelTextThe channel the campaign belongs to: paid search, paid social, display or videoMatches the channel values in the e-commerce dataset
campaign_idTextA stable identifier for the campaignSurvives the planted rename; join on this, not on the name
campaign_nameTextThe campaign name following the site's naming conventionOne campaign is renamed part-way through the period on purpose
spendDecimalMedia cost for the day in a single currencyOne day has a missing value in one campaign on purpose
impressionsIntegerImpressions servedDisplay and video rows carry far more impressions per unit of spend than search
clicksIntegerClicks recorded by the platformNever exceeds impressions
conversionsIntegerConversions attributed to the campaign by the analytics toolFalls to zero during the planted tracking gap while spend continues
revenueDecimalRevenue attributed to those conversionsZero wherever conversions are zero; varies per conversion by channel

Derived metrics are not stored. Cost per click, click-through rate, cost per conversion and return on spend are computed at query time, which is deliberate: an exercise that stores a ratio at daily grain and then averages it is making the most common reporting mistake, and the dataset is built to expose it.

How it was generated

The generator works per channel and per day. Each channel has a base cost per thousand impressions, a base click-through rate, a base conversion rate and a base revenue per conversion, chosen so that the channels differ in the way practitioners expect: search converts well on few impressions, display reaches widely and converts rarely, social and video sit between them. Each campaign has a daily budget drawn around its channel's typical level, and the daily figures are drawn from distributions centred on the base rates with noise added so that no two days are identical. The seed is fixed, so the same generator produces the same file every time; a reader who changes the seed gets different rows and the same patterns.

Four patterns are planted. A seasonal lift raises conversion rates across every channel in the final weeks of the quarter. A tracking gap, lasting a little over a week in the middle of the period, sets conversions and revenue to zero for paid search while spend, impressions and clicks continue, imitating a broken conversion tag. A creative change on one paid social campaign raises its click-through rate from a given date without changing its conversion rate, so that cost per click improves while cost per conversion does not. And a budget shift moves spend from display to video in the last month. Three faults are planted as data-quality practice: one campaign is renamed part-way through, a small number of rows are duplicated exactly, and one day in one campaign has a missing spend value. The data quality guide teaches the habits that catch each of them.

Sample rows

The rows below show the shape of the table. They are illustrative and generated; the values are not benchmarks for any channel.

Illustrative example — not a real result

Six rows from campaign_daily for the invented retailer

datechannelcampaign_idcampaign_namespendimpressionsclicksconversionsrevenue
2026-01-14paid_searchps_001uk-sales-sofas-2026q1112.406,18024391,386.00
2026-01-14paid_socialso_002uk-prospecting-spring_range-2026q1148.7541,9004026744.00
2026-01-14displaydp_001uk-prospecting-retargeting-2026q160.00118,3001712230.00
2026-02-19paid_searchps_001uk-sales-sofas-2026q1109.906,02023600.00
2026-02-19videovd_001uk-brand-spring_range-2026q195.0052,7001583372.00
2026-03-21paid_socialso_002uk-prospecting-spring_range-2026q1150.1040,6006117868.00

The second paid search row, dated 2026-02-19, sits inside the planted tracking gap: spend and clicks are normal and conversions are zero. The March paid social row sits after the planted creative change: clicks have risen by roughly half on similar impressions while conversions have not, so the click-through rate has moved from about 1.0 percent to 1.5 percent and cost per conversion has barely changed. Over the full quarter the retailer's paid search produces 520 conversions on £9,800 of spend and paid social 410 on £14,200, figures that exist only to give the exercises an answer key.

Questions it can answer and exercises

The dataset answers the questions a paid media review asks, and the exercises below take them in order of difficulty. First, aggregate: total spend, conversions and revenue by channel for the quarter, then cost per conversion and return on spend per channel. Compute the ratios from the sums, not as averages of daily ratios, and compare the two methods once to see how far they differ. The query without any literal numbers looks like this:

SELECT channel,
       SUM(spend) AS spend,
       SUM(conversions) AS conversions,
       SUM(spend) / SUM(conversions) AS cost_per_conversion,
       SUM(revenue) / SUM(spend) AS roas
FROM campaign_daily
GROUP BY channel
ORDER BY spend DESC;

Second, trend: the same metrics by week, charted, with the question of which week conversions rose across every channel at once and whether clicks rose with them. The planted seasonal lift answers it, and the difference between a lift in conversion rate and a lift in traffic is the lesson. Third, find the tracking gap: a run of days where one channel's spend and clicks continue and its conversions are zero. Decide, before reading the planted-pattern list, whether the gap is a market change or a measurement fault, and write down the evidence that decides it; the data quality guide gives the reasoning. Fourth, isolate the creative change: for the paid social campaign whose click-through rate steps up, compare cost per click and cost per conversion before and after the step and explain why one improved and the other did not. Fifth, handle the mess: join on campaign_id rather than campaign_name and see the renamed campaign become one; remove the duplicated rows and note how much they inflated spend; decide how to treat the day with missing spend. Finally, rebuild the channel summary as a dashboard with calculated fields following the calculated fields guide, and check the return on spend figures against the ROAS calculator to confirm the arithmetic.

Limits of synthetic data

Generated data is tidier than any export, and the tidiness is the limit. The channels behave as the rules say they behave; there is no competitor launch, no platform outage, no policy disapproval, no auction price spike, no public holiday beyond the seasonal lift. Attribution is a rule, not a model: a conversion belongs to one campaign on one day, where a real analytics tool would apply a window, a model and consent gaps that change the count. Revenue per conversion varies by channel and by noise only; there are no returns, cancellations or fraud. The three planted faults are the only faults, where a real export of the same size would contain a dozen kinds of mess nobody planted. The dataset therefore teaches method, particularly the discipline of computing ratios from sums, reading trends by week and separating measurement faults from market changes, and it does not teach judgement about what a channel should cost, which only a business's own history and the benchmarks guidance can inform.

Common mistakes

  • Quoting its figures. The base rates were chosen to be plausible, not representative; a cost per conversion from this table is a property of the generator.
  • Averaging daily ratios. A mean of daily cost per conversion weights quiet days equally with busy ones; sum the inputs first.
  • Joining on the campaign name. The planted rename splits one campaign into two; campaign_id is the key.
  • Reading the tracking gap as a market drop. Spend and clicks continuing while conversions vanish is the signature of a broken tag, here and in real accounts.
  • Ignoring the duplicates. A small number of exact duplicate rows inflate spend enough to move a channel's cost per conversion; de-duplicate before aggregating.
  • Treating noise as findings. Day-to-day movement is random by construction; patterns that are not on the planted list are almost always query errors.

Terms used on this page

Tools to try

Where this page is used

Part of these learning paths

Also related

Related