Count related rows from a filtered slice

Hi Team.

I have made a similary question before, but now I have clear which is the problem, and I want to tell you the detail in case that you can help me to resolve it. 

I have a Parent and a Childs tables. The Childs table has a related fields with Parent.

Parent table has a slice, called sl_Parent. Childs table has a slice called sl_Childs. The sl_Childs has a  filtered row sentence into Row filter condition field.

I need count the related Childs rows from Parent from rows showed into Slice (with a filter applied)   

COUNT([Related Childs]) (put into Parent table) count the related rows with the table, not only that the slice shows.

Is there a way to do it ??? I have looked for a solution by I can not find it

Thanks a lot again !

Omar

0 3 103
3 REPLIES 3

Two ways spring to mind

  1. add a VC that is. Ref_rows to the slice then just count that VC
  2. count ( select ( slice[key column], (filter condition) ))

Thank you alplacp, but both show the quantity records that slice return after the filter was applied. But I need see the quantity of related rows when the slice Row Filter Condition  is present

I will try to explain my need better. 

The Client showed in the screenshot has two equipment: one of Type " A" and another one of type "B"

If I my slice for Childs table (sl_Childs) has  the Row Filter Condition section empty, and I add a VC into Patent table called Quantity with the formula COUNT([related Childs]) I take some like this

GSuite_Omar_Poc_2-1644702732553.png

If I add the condition [Equipment]="A" into Row Filter Condition of sl_Childs

GSuite_Omar_Poc_3-1644703070472.png

The before screen should shows 1, but It shows 2

GSuite_Omar_Poc_2-1644702732553.png

I think that allways shows 2 because COUNT([related Childs]) is not related to sl_Childs slice results but related with the Childs table.

As I tell you, in this case, I need that the VC Equipment shows 1

Is it possible ???

 

Thanks a lot in advance

Omar

Please post a screenshot of the sl_Childs column configuration screen, including the Type Details section.

Top Labels in this Space