Hi Splunk community,
I have a lookup containing a list of allowed departments as the following
vendor
allowed_departments
F500
SADE/xxx,BTE,RAPH/NE
C99
SADE/xxx,RAPH/MS
I want to have a field valid check if the field of department matches with any values in allowed_deparments of corresponding vendor. But for allowed_departments value ends with "xxx" will accept the department if department has the same prefix of that value
For example: department of value "SADE/ER" will return Yes if allowed_departments contains "SADE/xxx"
Currently my SPL is like this
<my_search>
| lookup my_lookup vendor OUTPUT allowed_departments
| makemv delim="," allowed_departments
| eval valid = if(match(allowed_departments, department), "Yes", "No")
| fields - allowed_departments
Please advise if it is possible for Splunk to handle it.
Thanks,
... View more