Forum Discussion
Creating table from a table
- Anonymous3 years ago
Hi JiriRak ,
I created some data:
Here are the steps you can follow:
Create calculated table.
Table 1 = var _table= SUMMARIZE( 'Table','Table'[Contract ID],'Table'[Hedge type],'Table'[Hedge ID], "Count",COUNTX(FILTER(ALL('Table'),'Table'[Contract ID]=EARLIER('Table'[Contract ID])),[Hedge ID])) var _table2= FILTER( _table,[Count]<=2) return SUMMARIZE(_table2,[Contract ID],[Hedge type],[Hedge ID])Table 2 = var _table= SUMMARIZE( 'Table','Table'[Contract ID],'Table'[Hedge type],'Table'[Hedge ID], "Count",COUNTX(FILTER(ALL('Table'),'Table'[Contract ID]=EARLIER('Table'[Contract ID])),[Hedge ID])) var _table2= FILTER( _table,[Count]>2) return SUMMARIZE(_table2,[Contract ID],[Hedge type],[Hedge ID])If you want to implement filtering data greater than 2 of Total in a matrix:
Create measure.
Count_measure = COUNTX(FILTER(ALL('Table'),'Table'[Contract ID]=MAX('Table'[Contract ID])),[Hedge ID])Flag = IF( [Count_measure]<=2,1,0)Place [Flag]in Filters, set is=1, apply filter.
Result:
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi JiriRak ,
I created some data:
Here are the steps you can follow:
Create calculated table.
Table 1 =
var _table=
SUMMARIZE(
'Table','Table'[Contract ID],'Table'[Hedge type],'Table'[Hedge ID],
"Count",COUNTX(FILTER(ALL('Table'),'Table'[Contract ID]=EARLIER('Table'[Contract ID])),[Hedge ID]))
var _table2=
FILTER(
_table,[Count]<=2)
return
SUMMARIZE(_table2,[Contract ID],[Hedge type],[Hedge ID])
Table 2 =
var _table=
SUMMARIZE(
'Table','Table'[Contract ID],'Table'[Hedge type],'Table'[Hedge ID],
"Count",COUNTX(FILTER(ALL('Table'),'Table'[Contract ID]=EARLIER('Table'[Contract ID])),[Hedge ID]))
var _table2=
FILTER(
_table,[Count]>2)
return
SUMMARIZE(_table2,[Contract ID],[Hedge type],[Hedge ID])
If you want to implement filtering data greater than 2 of Total in a matrix:
Create measure.
Count_measure =
COUNTX(FILTER(ALL('Table'),'Table'[Contract ID]=MAX('Table'[Contract ID])),[Hedge ID])Flag =
IF(
[Count_measure]<=2,1,0)
Place [Flag]in Filters, set is=1, apply filter.
Result:
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
- JiriRak3 years agoHelper I
Amazing, thank you, I got really crazy yesterday with the SUMMARIZE and VAR, and couldn´t get through.