#771

Flag customers who barely buy

CRM wants to flag «dormant» customers — those whose total paid revenue (status = 'paid') is below 100. Support will follow up with them. For such customers set tier to 'dormant'. Important nuance: customers with no paid orders at all also count as dormant — interpret their revenue as zero, otherwise the < 100 comparison would silently skip them.

Just INSERT/UPDATE/DELETE — no trailing SELECT needed.

Your query result will appear here

Focus radio
Paused · SomaFM · Fluid