# Sumif Range

#### carianne

##### New Member
I have a sumif formula that references a range that I want to remain static. I update the data daily and sometimes the range varies based on how many patients are in our beds. The max it will ever be is 314. I used the following formula:
{=SUM(IF('Census By Service'!\$F\$2:\$F\$314="NEU",'Census By Service'!\$M\$2:\$M\$314,0))}

However, everyday the formula readjusts the range based on the data I enter, so I have to update the formula range daily. I want it to always look through the range max, but even adding the \$ sign before the range does not seem to accomplish this. Any suggestions?

### Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.

#### pgc01

##### MrExcel MVP
Hi carianne

You can use INDIRECT.

=SUM(IF(INDIRECT("'Census By Service'!\$F\$2:\$F\$314")="NEU",INDIRECT("'Census By Service'!\$M\$2:\$M\$314"),0))

This formula will always look at the same ranges even if you add or delete lines.

Hope this helps
PGC

#### sailepaty

##### Active Member
One more option,

=SUMIF('Census By Service'!\$F\$2:INDEX('Census By Service'!\$F:\$F,314),"NEU",'Census By Service'!\$M\$2:INDEX('Census By Service'!\$M:\$M,314))

Regards

Thanks so much!

Replies
5
Views
232
Replies
4
Views
409
Replies
6
Views
2K
Replies
1
Views
256
Replies
1
Views
280

1,136,305
Messages
5,674,984
Members
419,541
Latest member
freddyboots

### 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.

### Which adblocker are you using?

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

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