Forum Discussion
Generating dynamic rows and counting them
- 3 years ago
Hi ybyb23 ,
There are two reasons which may cause numeric fields not automatically summed:
1, The field data type is "this article" type.
2, There is a modeling relationship.
According to your description, I created a sample, and here is my solution.
Create a column.
count = IF ( COUNTROWS ( FILTER ( 'Sheet1', 'Sheet1'[Product ID] = EARLIER ( 'Sheet1'[Product ID] ) && 'Sheet1'[Product Name] = EARLIER ( 'Sheet1'[Product Name] ) && 'Sheet1'[Market] = EARLIER ( 'Sheet1'[Market] ) && 'Sheet1'[price] = EARLIER ( 'Sheet1'[price] ) && 'Sheet1'[size] = EARLIER ( Sheet1[size] ) ) ) > 0, "1", BLANK () )When you add rows to the table, you will get the final output.
I attach my sample below for your reference.
Best Regards,
Community Support Team _ xiaosunIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi ybyb23 ,
There are two reasons which may cause numeric fields not automatically summed:
1, The field data type is "this article" type.
2, There is a modeling relationship.
According to your description, I created a sample, and here is my solution.
Create a column.
count =
IF (
COUNTROWS (
FILTER (
'Sheet1',
'Sheet1'[Product ID] = EARLIER ( 'Sheet1'[Product ID] )
&& 'Sheet1'[Product Name] = EARLIER ( 'Sheet1'[Product Name] )
&& 'Sheet1'[Market] = EARLIER ( 'Sheet1'[Market] )
&& 'Sheet1'[price] = EARLIER ( 'Sheet1'[price] )
&& 'Sheet1'[size] = EARLIER ( Sheet1[size] )
)
) > 0,
"1",
BLANK ()
)
When you add rows to the table, you will get the final output.
I attach my sample below for your reference.
Best Regards,
Community Support Team _ xiaosun
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi v-xiaosun-msft,
thank you very much for your support. It worked perfectly!
Also I have approched it differently with the summerize function I have added all the fields name to count and it worked.