3 Replies Latest reply: Jan 29, 2017 7:08 AM by Richard Ouellette

# Filter Chart Expression Sum(If(Name='J*',1,0) Doesn't Work?

Good Morning

I have a simple chart with 1 expression above trying to tabulate 1st name counts based on the 1st Initial; typical 1st name fields are  John, Jane, Susan, Linda, Richard etc.  Can you suggest work around?  I also need to filter using Sum(If(Name<>'J*',1,0).

As an FYI Sum(If(Name Like 'J*',1,0) works but I  still would not have a solution for Sum(If(Name<>'J*',1,0). Can you help?

Thank!

Rick

• ###### Re: Filter Chart Expression Sum(If(Name='J*',1,0) Doesn't Work?

Wildcards can only be used in combination with some functions / operators, like

Name Like 'J*'

or

WildMatch( Name, 'J*')

Another option could be

Left(Name,1) = 'J'

• ###### Re: Filter Chart Expression Sum(If(Name='J*',1,0) Doesn't Work?

If you want to get the result for not equal, you can use the NOT operator or just change the then / else branch assignments:

Sum(If(Name LIKE 'J*',0,1))

Sum(If(not Name LIKE 'J*',1,0))

• ###### Re: Filter Chart Expression Sum(If(Name='J*',1,0) Doesn't Work?

Thank you Stefan for the quick response!