# Formula to return count for conditions

Options
✭✭✭✭✭✭

I am using this formula to count the number of assets for a particular month. Works fine.

=COUNTIFS([Next Step Calc]:[Next Step Calc], "All Complete", [End Date]:[End Date], IFERROR(MONTH(@cell), 0) = 2)

Now I need to have the formula account for a new year. I tried this and I'm getting INCORRECT AREGUEMENT SET.

=COUNTIFS([Next Step Calc]:[Next Step Calc], "All Complete", [End Date]:[End Date], =IFERROR(YEAR(@cell), 0) = 2021, IFERROR(MONTH(@cell), 0) = 2)

What am I doing wrong?

Thanks!

• ✭✭✭✭✭✭
Options

Hi @Jeana

Hope you are fine, try the following formula

=COUNTIFS([Next Step Calc]:[Next Step Calc], "All Complete", [End Date]:[End Date], YEAR(@cell) = 2021, [End Date]:[End Date], MONTH(@cell) = 2)

bassam.khalil2009@gmail.com

• ✭✭✭✭✭✭
Options

Hi @Jeana

Hope you are fine, try the following formula

=COUNTIFS([Next Step Calc]:[Next Step Calc], "All Complete", [End Date]:[End Date], YEAR(@cell) = 2021, [End Date]:[End Date], MONTH(@cell) = 2)

bassam.khalil2009@gmail.com

• ✭✭✭✭✭✭
Options

Hi @Jeana

I hope you're well and safe!

Try this.

=COUNTIFS([Next Step Calc]:[Next Step Calc], "All Complete", [End Date]:[End Date], IFERROR(YEAR(@cell), 0) = 2021, IFERROR(MONTH(@cell), 0) = 2)

Did that work/help?

I hope that helps!

Be safe and have a fantastic week!

Best,

Andrée Starå | Workflow Consultant / CEO @ WORK BOLD

SMARTSHEET EXPERT CONSULTANT & PARTNER

Andrée Starå | Workflow Consultant / CEO @ WORK BOLD

W: www.workbold.com | E:andree@workbold.com | P: +46 (0) - 72 - 510 99 35

Feel free to contact me for help with Smartsheet, integrations, general workflow advice, or anything else.

• ✭✭✭✭✭✭
Options

Hope you both are well too.

Thank you both, this worked!

Jeana

• ✭✭✭✭✭✭
Options

You are welcome

bassam.khalil2009@gmail.com

• ✭✭✭✭✭✭
Options

I'm excellent!

You're more than welcome!

SMARTSHEET EXPERT CONSULTANT & PARTNER

Andrée Starå | Workflow Consultant / CEO @ WORK BOLD

W: www.workbold.com | E:andree@workbold.com | P: +46 (0) - 72 - 510 99 35

Feel free to contact me for help with Smartsheet, integrations, general workflow advice, or anything else.

## Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!