Aller au contenu principal

Campaign QA Board: Spot the Predicate in the Wrong Place

Identify when a filter must run after grouping because it depends on an aggregate value.

SQL basics5 min read

One sticky note is trying to filter campaign groups before the groups exist. Where is the issue on Elise's QA board? Events joined to campaign records This is not the issue. Joining events to campaigns is the source-building step; the risk comes later when the aggregate threshold is placed too early. Last-week and signup-type row filters These filters belong before grouping because date and event type are facts on individual event rows. At-least-50 signups threshold before grouping Correct. A campaign's signup count exists only after events are grouped by campaign, so this threshold belongs in HAVING. Campaign summary output area…

Read the full lesson

Sign up free: one personalized lesson every day, matched to your role and goals.

← Back to library

Nous contacter