0

I'm working in a new org where we don't have any send data. I need to set up a suppression list for any subscriber that received 5 emails in the last 7 days. I am not 100% sure if my code below will work?

SELECT

SubscriberKey, 

COUNT(SubscriberKey) as TotalSent FROM _Sent

WHERE EventDate BETWEEN DATEADD(day, -7, CURRENT_TIMESTAMP) AND CURRENT_TIMESTAMP

GROUP BY SubscriberKey

HAVING COUNT (SubscriberKey) > 4
1
  • 1
    This should work exactly as you want it to. I personally utilize GetDate(), but CURRENT_TIMESTAMP seems like it will work as well. Apr 22, 2019 at 12:46

1 Answer 1

0

I don't see an issue with your code, your where clause could also be something along the lines of

WHERE eventdate > getdate() -7

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .