Forum Discussion
Create calcualated table
- Anonymous8 years ago
Hi Anonymous
There are many ways to do this.
If you want to do this in Power Query:
1. In Power Query ,Merge both tables and then apply Group by transfomation ( Transform -> Group by)
If you want to do this in DAX :
1. Define relationship between the tables.
2. Create a measure Count(Transactionid) and pull Branch id, area, Measure to get this data.
Thaks
Raj
- 8 years ago
Hi Anonymous,
In Power Query, you can combine these two tables via "Merge Query". The general steps are: Merge as new queries -> Group by -> Expand columns -> Remove duplicates.
If you want to create a calculated table via DAX, please refer to:
Combined table = ADDCOLUMNS ( SELECTCOLUMNS ( Branches, "BranchID", Branches[Branch ID], "Area", Branches[Area] ), "Count Transactions", CALCULATE ( COUNT ( Transactions[Transaction ID] ), FILTER ( Transactions, Transactions[Branch ID] = EARLIER ( [BranchID] ) ) ) )Best regards,
Yuliana Gu
Hi Anonymous,
In Power Query, you can combine these two tables via "Merge Query". The general steps are: Merge as new queries -> Group by -> Expand columns -> Remove duplicates.
If you want to create a calculated table via DAX, please refer to:
Combined table =
ADDCOLUMNS (
SELECTCOLUMNS (
Branches,
"BranchID", Branches[Branch ID],
"Area", Branches[Area]
),
"Count Transactions", CALCULATE (
COUNT ( Transactions[Transaction ID] ),
FILTER ( Transactions, Transactions[Branch ID] = EARLIER ( [BranchID] ) )
)
)
Best regards,
Yuliana Gu