Name contains exact match (India but not Indiana)

Get help. Get answers. Let others lend you a hand.

Moderator: Mr_Noodle

I would like to make a rule for all files that have the word India in their name and tag them Red. I set one up with the condition Name contains India but this also matches files with the word Indiana. How do I set things up so that the exact word India matches but not Indiana?
Anjadekar
 
Posts: 24
Joined: Sat Jun 03, 2017 4:33 pm

I'd suggest a rule as follows:

If all of the following conditions are met:
Name - contains - India
Name - does not contain - Indiana

This would still fail (ie positively match where you may not want a match) for files where the name contains "Indian", "Indians" etc
KevinC
 
Posts: 3
Joined: Sat Jan 13, 2018 4:26 pm

How does the word "India" appear? Like is there always a space afterwards? Or maybe some sort of punctuation?
Mr_Noodle
Site Admin
 
Posts: 11255
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Mr_Noodle wrote:How does the word "India" appear? Like is there always a space afterwards? Or maybe some sort of punctuation?


Not always. I thought of including a space before and after but I guess it wouldn't work for instances when the files is beginning with the word?
Anjadekar
 
Posts: 24
Joined: Sat Jun 03, 2017 4:33 pm

KevinC wrote:I'd suggest a rule as follows:

If all of the following conditions are met:
Name - contains - India
Name - does not contain - Indiana

This would still fail (ie positively match where you may not want a match) for files where the name contains "Indian", "Indians" etc


Thanks for that, Kevin, but I think it might get a little cumbersome to accommodate all the potential conflicts in the Does not contain condition.
Anjadekar
 
Posts: 24
Joined: Sat Jun 03, 2017 4:33 pm

Can you give examples of filenames in this case? Especially ones with non-spaces or non-punctuation after the word in question?
Mr_Noodle
Site Admin
 
Posts: 11255
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City


Return to Support