Forum Discussion
All data from Master to New table
I have master table which i need to create new table .. master data have 5648 Row and i need only Max date data which is 2056 or row will be ncrease dauly bases im using DAX function where i can get Max data from master bt in need new table where i can copy max data (2056) one to new table is there any possibilty to do this
here is Dax funtuin for measure
- Anonymous5 years ago
Hi SkorpionAAM ,
You could create a calculated column as flag for the master table to mark the rows which have max date then create a new table to filter these data by this flag.
Column = var max_date = MAXX(ALL('Table'),'Table'[date]) return IF('Table'[date]=max_date,1,0)Table 2 = FILTER('Table','Table'[Column]=1)Best Regards,
Jay
4 Replies
- amitchandakSuper User
SkorpionAAM , see like you are creating a measure try a measure like
Measure =
VAR __id = MAX ('GasStation',[place_digital_adress])
VAR __date = CALCULATE ( MAX('Table'[date] ), ALLSELECTED ('GasStation' ), 'GasStation',[place_digital_adress] = __id )
CALCULATE ( COUNTROWS ('GasStation'), VALUES ('Table'[place_digital_adress] ),'GasStation',[place_digital_adress] = __id,'GasStation'[date] = __date )or
measure = calculate(COUNTROWS ('GasStation'), filter(GasStation,GasStation[Date] = calculate(max(GasStation[Date]), allexpcept(GasStation,GasStation[place_digital_adress]))))
- SkorpionAAMHelper V
No thtas not my Requirment
- amitchandakSuper User
SkorpionAAM ,Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.
- AnonymousNot applicable
Hi SkorpionAAM ,
You could create a calculated column as flag for the master table to mark the rows which have max date then create a new table to filter these data by this flag.
Column = var max_date = MAXX(ALL('Table'),'Table'[date]) return IF('Table'[date]=max_date,1,0)Table 2 = FILTER('Table','Table'[Column]=1)Best Regards,
Jay