Ad Widget

Collapse

regex of time

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • albertosierra
    Junior Member
    • Feb 2014
    • 2

    #1

    regex of time

    I'd like to check if the last value of an item was generated in the first 5 minutes after an even hour to trigger an alert. I tried to use something like:

    Code:
    {template:item].time(0).regexp(^\d[02468][0][0-5])}=0
    when saving it returns an error: Incorrect trigger expression

    is this something that can be done in triggers is there a better way to acomplish it?
    Last edited by albertosierra; 18-02-2014, 21:45. Reason: typo
  • aib
    Senior Member
    • Jan 2014
    • 1615

    #2
    I don't have a solution but just confused of your reg.exp.
    Why you use the wrong slash?

    for me it has to looks like
    ^\d[02468][0][0-5]
    Sincerely yours,
    Aleksey

    Comment

    • albertosierra
      Junior Member
      • Feb 2014
      • 2

      #3
      that was a typo. when i created the post. the regexp was correctly added to the trigger
      Last edited by albertosierra; 19-02-2014, 00:08.

      Comment

      Working...