Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Counting displayed table rows

Hi,

I have 2 tables when I select from the fist one the second table is updated, can anyone please tell me how to count the rows in the second table? getselectedcount is not working because selection is done from the fist table.

Thank you.

1 Solution

Accepted Solutions
trdandamudi
Master II
Master II

Here is the complete script and the expression:

Tbl1:

Load * Inline [

ID

1

2

3

4

];

Tbl2:

Load * Inline [

ID,Type

1,A

1,A

2,B

3,C

3,C

3,C

4,D

4,D

4,D

4,D

4,D

];

Expression:

=If(GetSelectedCount(ID)=0,'',Count(Type))

Note: If nothing is selected then it will not show any count and that is the reason I am using IF condition.

Hope this helps...

View solution in original post

12 Replies
its_anandrjs

Can you share some sample for this.

Anonymous
Not applicable
Author

I have a table that has some information selected from database and I have another table that display more information when a selection is made from the first table, now what I want to do is to count the number of records displayed in the second table


for example I have table tbl1 and tbl2

tbl1

1

2

3

4

tbl2

A

B

C

D

So when I select 1 for example form the first table the second table will display the records depending on the relation between the 2 tables, I want to know how to count the number of  records displayed in  tbl2. I tried to use getselectedcount but it does not work because there is not selection happened on tbl2.

I hope this made it more clear.

Thank you.

trdandamudi
Master II
Master II

Is this what you are looking for ?

its_anandrjs

Obviously it is due to the Qlikview Associative properties due that it is happen why you count that value you can view it on the UI part that how may records get selected. You can use property Show Frequency in list object of another table and it visible to you on each record.

Disp.PNG

Hope this make sense

its_anandrjs

See smale example for this

Anonymous
Not applicable
Author

I am using qlik sense and I want to display the count in KPI, I can't open the example it is not showing any data.

Anonymous
Not applicable
Author

I am using qlik sense, in the example you sent what is 5 representing? is this the count of rows of another table?

trdandamudi
Master II
Master II

Yes, the 5 is representing the count of rows of another table...

Anonymous
Not applicable
Author

can you please send me the expression that you used.

Thank you.