Forum Discussion
AllanBerces
Post Prodigy
2 years agoExclude Specific Category
Hi Good day, Can anyone help me to edit my calculated column. I want to exclude one category in Table 1 (columnA) note: (columnA) is available in Table 2 Earned = CALCULATE ( SUM ( 'Table...
- 2 years ago
Hi AllanBerces - you can create below logic to exclude the category to modify your Earned calculated column in Power BI and exclude a specific category . replace with your table and column names
Earned =
CALCULATE (
SUM ( 'Table 1'[Earned] ),
FILTER (
ALL ( 'Table 1' ),
'Table 1'[Week No.] = EARLIER ( 'Table 2'[Week No.] ) &&
'Table 1'[Year] = EARLIER ( 'Table 2'[Year] ) &&
'Table 1'[Trade] IN { "MECH", "CIVIL", "ELEC" } &&
'Table 1'[ColumnA] <> "CategoryToExclude" -- Add this condition to exclude the category
)
)Hope this works.
AllanBerces
Post Prodigy
2 years agoHi rajendraongole1 thank you for the help, working as in need
rajendraongole1
Super User
2 years ago