When using a custom date field as a trigger condition, what does "is within the previous" and "is within the next" do?

Have more questions? Submit a request

16 Comments

  • Divya Arumugam
    Comment actions Permalink

    Hey Brett,

    I would like to know how to set up a trigger for the scenario that Sergio has mentioned. I want to set up a trigger where a ticket status changes from 'on-hold' to 'open' when Custom Date field is 'today'

    Will the trigger work if I set the value '0' as shown below? Thanks in advance!

    1
  • Andrew J
    Comment actions Permalink

    Hey Bart, try just 1 rather than >1.  I think Brett was just using > to show the steps.

    0
  • Andrew J
    Comment actions Permalink

    Oh that is interesting.  But it does make slight sense.  The day has arrived, and therefore it is not longer upcoming. Makes some sense that it is now previous rather than 'next'.  I guess it is missing an option for "is  'TODAY' "

    Thanks for letting me know.

    0
  • Sergio Anarte
    Comment actions Permalink

    Hi James,

    How can we reproduce the next escenario within a trigger condition?

    Scenario: Trigger should be executed when a custom field contains the current date (i.e. today)

    - Custom Date field is within the next 0 days.

    We can't make it work, is there any workaround?

    Thank you.

    0
  • Andrew J
    Comment actions Permalink

    Just to confirm, this is a trigger.. so you are updating the ticket yourself and want the trigger to fire when you submit it? As opposed to an automation that runs when the conditions are met. Is that correct?

    0
  • Bart Brosens
    Comment actions Permalink

    these are the conditions i'm using:

    0
  • Brett - Community Manager
    Comment actions Permalink

    Hey Bart,

    I was able to use this condition within a view on my own test account.

    What other conditions are you attempting to add to this view?

    I just used Status > Less than > Solved along with the due date condition.

    Let me know!

    0
  • Kris Mendoza
    Comment actions Permalink

    Hey Brett,

    I actually figured it out - I selected the wrong parameter in one of the conditions.  Thanks for the prompt reply though!

    0
  • Brett - Community Manager
    Comment actions Permalink

    Glad to hear it Kris :)

    Let us know if you have any other questions!

    0
  • Bart Brosens
    Comment actions Permalink

    Yea, I figured that was a misunderstanding of me.

     

    However, when I fill in “within the next 1 days”, it doesn’t give me the tickets where the custum date field is set for the current day.

    Only for tickets for the next day.

     

     

     

    0
  • Kris Mendoza
    Comment actions Permalink

    Hello!

    I'd like to know how to do the scenario that Sergio posted.  We are creating an "alert" for any customers who are within a certain contract renewal date and it's not working when we generate new tickets.

    We're using triggers as this only needs to fire when the ticket is submitted.

     

    Thanks,
    Kris

    0
  • Bart Brosens
    Comment actions Permalink

    I've experimented with this as well..

    Strangely, "within the next 2 days" only gives tickets dated "tomorrow", not "today"

     

    So far, I've only been able to create the tickets of "today" when I use "within the previous 1 day"

    So I think I'll use that

     

    Thanks for having a look! :)

    0
  • Brett - Community Manager
    Comment actions Permalink

    Hey Kris,

    Any chance you could provide a screenshot of the trigger you have set up so we can take a look? You'll also want to keep in mind that these conditions work in multiples of 24 hours. So if you'd like the Trigger to fire within 48 hours of their contract renewal date, you'll need to use the within the next > 2 condition.

    Keep me posted!

    0
  • Brett - Community Manager
    Comment actions Permalink

    Hi Divya,

    If you're want to re-open the ticket automatically, you'll want to use an automation instead of a trigger. Example screenshot for you below:

    I wouldl also recommend using Is within the next > 1 days instead of 0 as I'm not sure if the automation will fire then.

    Let me know if you have additional questions for me!

    0
  • Bart Brosens
    Comment actions Permalink

    Hi there!

    @Brett,

    I wanted to use your "is within the next > 1 days " in a condition in a view, but It gives me an error:

    Basicly, I wanted to create a view where we can view the tickets where a custom date field has the date of today.

    Am i doing something wrong?

     

    Thanks

    regards

    Bart

     

     

     

    0
  • Andrew J
    Comment actions Permalink

    Sorry, I see this is for a view. Brett was talking about a trigger.

    What happens if you try 2 days?  Does that show the ones you want... and some?

    0

Please sign in to leave a comment.

Powered by Zendesk