Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hello,
A bit new to Power BI here, so go easy on me.
I have two tables, table A and table B. Table A has a lot of customer numbers and their revenue for each transaction, while table B just has the distinct customer. I want to create a second column in Table B that has the sum of all the revenue from Table A for each of those customers. How can I do this?
Thanks
Solved! Go to Solution.
If for some reason the tables do not have a relationship...you can use this column
Column = CALCULATE ( SUM ( TableA[Revenue] ), FILTER ( TableA, TableA[CustomerNo] = TableB[CustomerNo] ) )
Hi,
Create a relationship from the Customer Name column of Table A (Revenue) to the Customer Name column of Table B (Customers). Write this calculated column formula in Table B (Customers)
=SUMX(RELATEDTABLE(Revenue),[Revenue])
Hope this helps.
Hi @epmck11
If the 2 tables are related to each other via customer column...then you can use this calculated column
Column = CALCULATE ( SUM ( TableA[Revenue] ) )
If for some reason the tables do not have a relationship...you can use this column
Column = CALCULATE ( SUM ( TableA[Revenue] ), FILTER ( TableA, TableA[CustomerNo] = TableB[CustomerNo] ) )
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
110 | |
109 | |
89 | |
76 | |
66 |
User | Count |
---|---|
125 | |
111 | |
100 | |
83 | |
71 |