I need to suppress messages based on date, meaning if the message coming in is older than 30 days. I don’t know how to format the condition based on the MSH.7 value. Can you assist?
If in an Xlate and depending on what release of Cloverleaf you are using, the STRING Action and some other Actions could possibly do the trick.
A lot depends on how the MSH-7 field is really formatted in the messages. Not all systems follow the Date/Time format prescribed for the MSH Date/Time field. SO how is yours formatted?
email: jim.kosloskey@jim-kosloskey.com 29+ years Cloverleaf, 59 years IT - old fart.
I should have known that you and that gorgeous car would show up! I’m using version 20.1, and MSH.7 is formatted 20221209091927 – Year/month/day/time. Thank you so much for your time!
Why would you want to incur all of the processing up through Xlate just to kill it? A simple proc in the IB tab would solve it. Just extract MSH.7, do the math and return KILL if over 30 days.
Take a look at the clock command for how to do this. Off the top of my head see below. There may be more eloquent methods.
set msh7 20230210123212 ;#MSH 7 value
# make it scanable then get seconds
set then [clock scan “[string range $msh7 0 7] [string range $msh7 8 end]”]