Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Varan_15
Helper III
Helper III

How to calculate positive values based on existing measure

Hi All,

 

I have table account level balance amount if wherever blank values then i created measure 1 to fetch data from previous day.

 

now i have measure 1 for the date wise, I have to create another measure to calculate positive values only from existing measure 1.

 

CALENDAR_DATEholidayACCOUNT_NOBalanceMeasure 1
01/04/2024 0:00weekday110166988.6256988.625
02/04/2024 0:00weekday11016 6988.625
03/04/2024 0:00weekday11016200200
04/04/2024 0:00weekday11016-63620.463-63620.463
05/04/2024 0:00Weekend11016 -63620.463
06/04/2024 0:00Weekend11016 -63620.463
07/04/2024 0:00weekday11016-31.359-31.359
08/04/2024 0:00weekday11016-31.359-31.359
09/04/2024 0:00Holiday11016 -31.359
10/04/2024 0:00Holiday11016 -31.359
11/04/2024 0:00Holiday11016168.641168.641
12/04/2024 0:00Weekend11016 168.641
13/04/2024 0:00Weekend11016 168.641
14/04/2024 0:00weekday11016-31.359-31.359
15/04/2024 0:00weekday11016168.641168.641
16/04/2024 0:00weekday11016168.641168.641
17/04/2024 0:00weekday11016168.641168.641
18/04/2024 0:00weekday11016-31.359-31.359
19/04/2024 0:00Weekend11016 -31.359
20/04/2024 0:00Weekend11016 -31.359
21/04/2024 0:00weekday11016168.641168.641
22/04/2024 0:00weekday11016168.641168.641
23/04/2024 0:00weekday11016-31.359-31.359
24/04/2024 0:00weekday11016978.685978.685
25/04/2024 0:00weekday11016168.569168.569
26/04/2024 0:00Weekend11016 168.569
27/04/2024 0:00Weekend11016 168.569
28/04/2024 0:00weekday11016168.569168.569
29/04/2024 0:00weekday11016-10915.165-10915.165
30/04/2024 0:00weekday11016166.78166.78

 

expected result:

for this customer (11016) -> April month total value will be : 17346.119

 

kindly help me to create measure.

 

Thanks in advance

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Varan_15 

 

Thanks for the reply from @Tahreem24  .

 

@Varan_15 , please try the following measure.

 

Measure = SUMX(FILTER('Table', [Measure1] > 0), [Measure1])

 

 

Output:

vxuxinyimsft_0-1721888176361.png

 

Because I don't know what the calculation logic of your measure1 is, the measure1 I wrote is just to restore your scenario.

 

Best Regards,
Yulia Xu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
Tahreem24
Super User
Super User

@Varan_15  Try this measure:

Measure = CALCULATE([Measure1],FILTER('Table',[Measure1]>0))
Tahreem24_0-1720709521313.png

 

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard

@Tahreem24 ,

 

Thanks for the update,

 

 

I have used the same measure logic but total is wrong. PFB

 

CALENDAR_DATEACCOUNT_NOHolidaysum of balanceMeasure 1Final Measure
01/04/2024 0:0011016weekday6988.6256988.6256988.625
02/04/2024 0:0011016weekday 6988.625 
03/04/2024 0:0011016weekday200200200
04/04/2024 0:0011016weekday-63620.463-63620.463 
05/04/2024 0:0011016Weekend -63620.463 
06/04/2024 0:0011016Weekend -63620.463 
07/04/2024 0:0011016weekday-31.359-31.359 
08/04/2024 0:0011016weekday-31.359-31.359 
09/04/2024 0:0011016Holiday -31.359 
10/04/2024 0:0011016Holiday -31.359 
11/04/2024 0:0011016Holiday168.641168.641168.641
12/04/2024 0:0011016Weekend 168.641 
13/04/2024 0:0011016Weekend 168.641 
14/04/2024 0:0011016weekday-31.359-31.359 
15/04/2024 0:0011016weekday168.641168.641168.641
16/04/2024 0:0011016weekday168.641168.641168.641
17/04/2024 0:0011016weekday168.641168.641168.641
18/04/2024 0:0011016weekday-31.359-31.359 
19/04/2024 0:0011016Weekend -31.359 
20/04/2024 0:0011016Weekend -31.359 
21/04/2024 0:0011016weekday168.641168.641168.641
22/04/2024 0:0011016weekday168.641168.641168.641
23/04/2024 0:0011016weekday-31.359-31.359 
24/04/2024 0:0011016weekday978.685978.685978.685
25/04/2024 0:0011016weekday168.569168.569168.569
26/04/2024 0:0011016Weekend 168.569 
27/04/2024 0:0011016Weekend 168.569 
28/04/2024 0:0011016weekday168.569168.569168.569
29/04/2024 0:0011016weekday-10915.165-10915.165 
30/04/2024 0:0011016weekday166.78166.78166.78
Total  -65009.349-184712.6669683.074
Anonymous
Not applicable

Hi @Varan_15 

 

Thanks for the reply from @Tahreem24  .

 

@Varan_15 , please try the following measure.

 

Measure = SUMX(FILTER('Table', [Measure1] > 0), [Measure1])

 

 

Output:

vxuxinyimsft_0-1721888176361.png

 

Because I don't know what the calculation logic of your measure1 is, the measure1 I wrote is just to restore your scenario.

 

Best Regards,
Yulia Xu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Kudoed Authors