Daily Count of Dormant Instagram Creators With No Post in Fourteen Days

Last updated: November 29, 2026

Quick Overview

For each day in the last 60 days, count Instagram creators who have posted at least once before but have gone 14 or more days without posting as of that day. Build the daily series without scanning every creator for every day.

Meta
Data Manipulation (SQL/Python)
Data Scientist
Meta
November 29, 2026
Data Scientist
Onsite
Data Manipulation (SQL/Python)
Hard

0

0

0 solved


For each day in the last 60 days, count Instagram creators who have posted at least once before but have gone 14 or more days without posting as of that day. Build the daily series without scanning every creator for every day.

A creator health question for Instagram data scientists, where the dormant-creator count is tracked alongside new and active creators. The interviewer checks whether you convert events into state intervals and join those to a calendar, rather than computing 'days since last post' with a full cross join.

What the Interviewer Expects
  • Reduce to distinct creator post dates
  • Use LEAD to find the next post after each post
  • Turn each gap into a dormant interval starting 14 days after a post
  • Close the last interval at the report end
  • Join intervals to a calendar and count per day
Key Topics to Cover
state intervals
LEAD
calendar join
dormancy
creator health
How to Approach This
  1. Clarify the schema and expected output format before writing queries.
  2. Use CTEs (WITH clauses) to break complex queries into readable steps.
  3. Consider window functions (ROW_NUMBER, RANK, LAG, LEAD) for ranking and sequential analysis.
  4. Watch for NULLs, duplicates, and edge cases in JOINs and GROUP BY.
  5. For pandas, prefer vectorized operations over row-by-row iteration.
Possible Follow-up Questions
  • How would you also count creators returning from dormancy each day?
  • What if the threshold changes to 30 days for a different report?
  • How does a creator who deleted their account fit in?
  • How would you maintain this incrementally?
Sharpen Your Skills on Codemia

Practice similar problems with our interactive workspace, get AI feedback, and track your progress.

Practice SQL Problems
Sample Answer
Clarify the Data

ig_posts(post_id, creator_id, created_at). Dormant on day D means the creator's most recent post on or before D is at least 14 days earlier, i.e. last post date at most D - 14. Creators who have nev...

Approach

For each post date p with next post date n, the creator is dormant on days p + 14 through n - 1. If there is no next post, the interval runs to the report end. That gives at most one interval per post...


Submit Your Answer
Markdown supported