Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Row count based on selections

I have a straight table with about 17 000 records.  I have created a textboox with a Count(Distinct(TradeName)) which counts the number of distinct TradeNames in the straight table as is illustrated below:

Screen Shot 2015-12-09 at 15.06.04.png

The distinct count of TradeName gives a value of 3801 as illustrated above.  I would want this value to change based on various selections with various dimension values for example filter by date which should reduce the number 3801.

How can this be accomplished in QV?

1 Solution

Accepted Solutions
roger_stone
Creator III
Creator III

Shouldn't you be counting [FDA Trade Name] ?

View solution in original post

13 Replies
Anonymous
Not applicable
Author

It should work automatically with this expression: Count(Distinct(TradeName))

You no need to do anything..

If your selected Dimension is associated with TradeName...It will change as per your selection

sunny_talwar

I think it should already change if this -> Count(DISTINCT TradeName) is what you are using. It is not filtering based on selections?

Anonymous
Not applicable
Author

Many thanks, it is not changing based on any selections.

Anonymous
Not applicable
Author

Hi Sunny

There are no changes based on any selections.

roger_stone
Creator III
Creator III

Is the table 'Detached'?

Capture.PNG

Anonymous
Not applicable
Author

HI Roger, thanks, it is not detached.

My data model is as below:

Screen Shot 2015-12-09 at 15.41.56.png

Anonymous
Not applicable
Author

Sample Data?

roger_stone
Creator III
Creator III

Shouldn't you be counting [FDA Trade Name] ?

Anonymous
Not applicable
Author

I cannot see field TradeName in your Data Model.

Should it be Count ( Distinct ( [FDA TradeName] ) ) ?

Or maybe I am missing something.