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
I have two tables one with the date values (unique) and another table with date values (repeated) and with different values that I want to sum based on the date and the column of "line" excluding line 4.
Example:
Best regards!
Solved! Go to Solution.
Hi @XaviOV ,
Just create calculated column in table1:
column =
CALCULATE (
SUM ( 'Table2'[plts] ),
FILTER (
'Table2',
'Table2'[Week] = EARLIER ( 'Table1'[Week] )
&& 'Table2'[line] <> 4
)
)
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Best Regards,
Dedmon Dai
Hi @XaviOV ,
Just create calculated column in table1:
column =
CALCULATE (
SUM ( 'Table2'[plts] ),
FILTER (
'Table2',
'Table2'[Week] = EARLIER ( 'Table1'[Week] )
&& 'Table2'[line] <> 4
)
)
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Best Regards,
Dedmon Dai
@XaviOV , Not very clear,
you can join both of the tables, if dates are unique in table 2 .you can join them together and analyze. Or join to common date table and analyze
In such case
use measure = calculate(sum(Table1[pits]), filter(Table1,Table1[line]<>4))
if you want table2 from table1
table 2 = summarize( Table, Table[Week], "Suma plts",calculate(sum(Table1[pits]), filter(Table1,Table1[line]<>4)))
if you want new column in table2 from table 1
New column in table 2 = sumx(filter(Table1,Table1[line]<>4 && Table1[week] = Table2[week]),sum(Table1[pits]))
@XaviOV
Go to Modeling Table > New Table and Paste the following code, it will create anew table with the result as you expect.
Table5 Summarized =
SUMMARIZE(
FILTER(Table5,Table5[line]<>4),
Table5[Week],
"Total", SUM(Table5[plts])
)
________________________
If my answer was helpful, please consider Accept it as the solution to help the other members find it
Click on the Thumbs-Up icon if you like this reply 🙂
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
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 | |
95 | |
76 | |
65 | |
51 |
User | Count |
---|---|
146 | |
109 | |
106 | |
88 | |
61 |