Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to add column to existing expression?

Hi,

I have below expression in chart

=COUNT({<[Status] -= {'SalesCounter','Ground'}>}DISTINCT CustomerID)

I need to add one more column Region to above expression.

The region have blanks and 3,4. But I need to add only Region =3,4.

How to add the Region to the existing expression? Can anyone suggest me.

Thanks.

1 Solution

Accepted Solutions
MK_QSL
MVP
MVP

=COUNT({<[Status] -= {'SalesCounter','Ground'}, Region = {'3','4'}>}DISTINCT CustomerID)

View solution in original post

4 Replies
MK_QSL
MVP
MVP

=COUNT({<[Status] -= {'SalesCounter','Ground'}, Region = {'3','4'}>}DISTINCT CustomerID)

Not applicable
Author

Thanks. how to change the same expression if I need to show all integers in Region except blanks?

awhitfield
Partner - Champion
Partner - Champion

=COUNT({<[Status] -= {'SalesCounter','Ground'}, Region = {'*'}>}DISTINCT CustomerID)

MK_QSL
MVP
MVP

Region = {'*'}

or Create below in your script

IF(IsNull(Region) or Len(Trim(Region))=0, 0, 1) as RegionNotNullFlag

Now instead of Region = something......use

RegionNotNullFlag= {'1'}