Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
cheburashka
Creator III
Creator III

What is the logical operator for "NOT" in a search string?

Hello,

I've read some posts about search strings but couldn't find the NOT operator.

I would like to write a searchstring when I try to select some values in a listbox:

(*XXX* & "NOT" *Archive*)

My goal is to select all values from the field "FolderPath" that contain the string "XXX" but NOT the string "Archive".

What is the correct syntax for this?

,Thanks in advance, Koen

Message was edited by: Koen Bal

1 Solution

Accepted Solutions
maxgro
MVP
MVP

=Field like '*XXX*' and not Field like '*Archive*'

View solution in original post

13 Replies
sunny_talwar

Not sure I understand the requirement? Where are you using this?

Anonymous
Not applicable

Something like this ?

=if ( WildMatch ( 'BLAHappleBLAHlemonadeBLAH' , '*apple*' )

and not WildMatch ( 'BLAHappleBLAHlemonadeBLAH' , '*lemonade*' )

, 'Y' , 'N' )

=if ( WildMatch ( 'BLAHappleBLAHlemonadeBLAH' , '*apple*' )

and not WildMatch ( 'BLAHappleBLAHlemBLAHonadeBLAH' , '*lemonade*' )

, 'Y' , 'N' )

PradeepReddy
Specialist II
Specialist II

Test:

Load * inline

[

String_Field

ABCXXXDEFArchive

DEFArchiveABC

ABCXXX

XXXDEF

ABCXXXDEF

ArchiveABC

ABCArchive

];

Try the expression in list box:  if(wildmatch(String_Field,'*XXX*') and not WildMatch(String_Field,'*Archive*'),String_Field)

NareshGuntur
Partner - Specialist
Partner - Specialist

Are you looking something similar to this?

List box has 3 values and when I give -WD, WD has been filtered out.

exclude_selection.png

Anonymous
Not applicable

*XXX* & "NOT" *Archive* in same string?

sasikanth
Master
Master

Hi,

Try this

Search expression in listbox

Wildmatch(Filedname,'*XXX*') and not wildmatch(Fieldname,'*Archive*')

swuehl
MVP
MVP

Try

("*XXX*" ^"*Archive*")

Anonymous
Not applicable

Never new about the ^ I'll remember that. 

Thanks.

cheburashka
Creator III
Creator III
Author

Doesn't seem to work...