Refer to the corresponding Cell in another column in SUMIFS

SanjayGMusafir

Well-known Member
Joined
Sep 7, 2018
Messages
1,503
Office Version
  1. 2021
Platform
  1. MacOS
Hi Experts

I'm using a SUMIFS formula that was working fine till today. Now I want a new dimension added to it which I'm not able to figure out. If you may please help.

Required -
If there is some value in Banks[Less] and there is a corresponding Value in Banks[Add] then it should subtract that amount from the total. But should ignore all such values in Banks[Add] where there is no value/blank in Banks[Less].

The formula I'm using right now is...

Thanks in Advance

Excel Formula:
=IFS(TODAY()<DATE(YEAR(TODAY()),8,2),
ROUND(50000-SUMIFS(Banks[Less],Banks[Acc],"CC SH ICICI",Banks[D1],"<>"&"Petrol",Banks[Dt],">="&DATE(YEAR(TODAY())-1,8,2),Banks[Dt],"<"&DATE(YEAR(TODAY()),8,2),Banks[Dt],"<="&TODAY()),2),
TRUE,
ROUND(50000-SUMIFS(Banks[Less],Banks[Acc],"CC SH ICICI",Banks[D1],"<>"&"Petrol",Banks[Dt],">="&DATE(YEAR(TODAY()),8,2),Banks[Dt],"<"&DATE(YEAR(TODAY())+1,8,2),Banks[Dt],"<="&TODAY()),2))
 

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!
I solved it by doing...

Any better way of doing it...

Excel Formula:
=IFS(TODAY()<DATE(YEAR(TODAY()),8,2),
ROUND(50000-
(SUMIFS(Banks[Less],Banks[Acc],"CC SH ICICI",Banks[D1],"<>"&"Petrol",Banks[Dt],">="&DATE(YEAR(TODAY())-1,8,2),Banks[Dt],"<"&DATE(YEAR(TODAY()),8,2),Banks[Dt],"<="&TODAY())
-SUMIFS(Banks[Add],Banks[Less],"<>"&"",Banks[Acc],"CC SH ICICI",Banks[D1],"<>"&"Petrol",Banks[Dt],">="&DATE(YEAR(TODAY())-1,8,2),Banks[Dt],"<"&DATE(YEAR(TODAY()),8,2),Banks[Dt],"<="&TODAY())),2),
TRUE,
ROUND(50000-
(SUMIFS(Banks[Less],Banks[Acc],"CC SH ICICI",Banks[D1],"<>"&"Petrol",Banks[Dt],">="&DATE(YEAR(TODAY()),8,2),Banks[Dt],"<"&DATE(YEAR(TODAY())+1,8,2),Banks[Dt],"<="&TODAY())
-SUMIFS(Banks[Add],Banks[Less],"<>"&"",Banks[Acc],"CC SH ICICI",Banks[D1],"<>"&"Petrol",Banks[Dt],">="&DATE(YEAR(TODAY()),8,2),Banks[Dt],"<"&DATE(YEAR(TODAY())+1,8,2),Banks[Dt],"<="&TODAY())),2))
 
Upvote 0

Forum statistics

Threads
1,223,723
Messages
6,174,117
Members
452,545
Latest member
boybenqn

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top