Re: Setting up a recurrence to null out a field every 6 hours

Patrick_Vesely
Level 3

Setting up a recurrence to null out a field every 6 hours

Hi, 

Our analytics team is asking us to null out a field every 6 hours.  We are trying to think of all our options and wondering what the best approach is.  

 

has anyone done something like this before?  best solution?

Patrick Vesely
6 REPLIES 6
marypaine
Level 2

Re: Setting up a recurrence to null out a field every 6 hours

My first thought is that you'd have to schedule multiple recurring batch campaigns (4) since the highest frequency that you can have a single one run is daily. So you could space them out whatever way makes sense for your analytics team, but it could look something like:

  • Batch 1: 8am
  • Batch 2: 2pm
  • Batch 3: 8pm
  • Batch 4: 2am
Patrick_Vesely
Level 3

Re: Setting up a recurrence to null out a field every 6 hours

thank you. the batch idea was discussed but we would run into too many issues.  We are going with a trigger smart campaign and waiting 6 hours after new value has been added to the field

Patrick Vesely
Loressa_Copelan
Level 2

Re: Setting up a recurrence to null out a field every 6 hours

I was thinking the same thing, using batch. I was also thinking about wait steps, but not sure how that would work with clearing out data.

Loressa Copeland
SanfordWhiteman
Level 10 - Community Moderator

Re: Setting up a recurrence to null out a field every 6 hours

6 hours after the last change to the field?

 

Or every 6 hours regardless of when/whether it’s changed? This you can do with 4 scheduled batch campaigns per day.

 

Though either way it sounds like some disastrous decisions preceded this IMO.

Patrick_Vesely
Level 3

Re: Setting up a recurrence to null out a field every 6 hours

I do not disagree.   The first thought was to run an update at 12am, 6am, 12pm, and 6pm. 

 

But we have set this up as a trigger smart campaign with a 6 hour wait setp....after new values have been added to the field.  

Patrick Vesely
SanfordWhiteman
Level 10 - Community Moderator

Re: Setting up a recurrence to null out a field every 6 hours

It’s gonna depend on how often the field is updated and how much of the database is affected.

 

A specific concern is what happens if the field is changed at, for example, hour 1, hour 3, and hour 5 β€” that means three different NULLing runs even though the final result at hour 6 is the same.

 

Why do they need you to NULL it out exactly?