[exim] Exim filter get number before the dot

Top Page
Delete this message
Reply to this message
Author: Sławomir Dworaczek
Date:  
To: exim-users
Subject: [exim] Exim filter get number before the dot
Heloo
In exim filter, numeric values in the "is above" rule are only accepted as integers
I have to execute the delivery command if the header value is above some number,
unfortunately many of them are written in the header and are decimal numbers, as a result I get an error
error in filter file: malformed numerical string "16.34"
here is my expression
if
$h_X-Spam-Potential: is not "" and ${sg{$h_X-Spam-Potential:}{^(\d+)\..*}{$1}} is above 16
then
......
theoretically, only the number 16 before the dot should be taken into account but unfortunately this doesn't happen :( thanks for help Slawek

--
## subscription configuration (requires account):
## https://lists.exim.org/mailman3/postorius/lists/exim-users.lists.exim.org/
## unsubscribe (doesn't require an account):
## exim-users-unsubscribe@???
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/