AND function
Hi
I am trying to write a formula that would count the number of calls in the last 15 days. Below is my formula. I am first looking at my date column so that it is in between today and 15 days ago. Then I need to only count for if the Type of Dealer (Single Select Drop Down) = DAP Dealer and Merchant if they are New and Onsite. I am receiving a the following error message - #INVALID Operation. What am I missing? I have looked at this formula and I don't see what I am missing.
=COUNTIFS(Date:Date, AND(@cell <= TODAY(), @cell > TODAY(-15)), AND([Type of Dealer]:[Type of Dealer] = "DAP Dealer", [Type of Dealer]:[Type of Dealer] = "Merchant"), [New / Existing]:[New / Existing], "New", [Activity Type]:[Activity Type], "Onsite")
Best Answer
-
I hope you're well and safe!
Try something like this.
=COUNTIFS(Date:Date, AND(@cell <= TODAY(), @cell > TODAY(-15)), [Type of Dealer]:[Type of Dealer], OR(@cell = "DAP Dealer", @cell = "Merchant"), [New / Existing]:[New / Existing], "New", [Activity Type]:[Activity Type], "Onsite")
Did that work/help?
I hope that helps!
Be safe, and have a fantastic weekend!
Best,
Andrée Starå | Workflow Consultant / CEO @ WORK BOLD
✅Did my post(s) help or answer your question or solve your problem? Please support the Community by marking it Insightful/Vote Up, Awesome, or/and as the accepted answer. It will make it easier for others to find a solution or help to answer!
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.
Answers
-
@Carol-Anne Cerbone This AND function: AND([Type of Dealer]:[Type of Dealer] = "DAP Dealer", [Type of Dealer]:[Type of Dealer] = "Merchant")
should be: AND([Type of Dealer]:[Type of Dealer] , "DAP Dealer", [Type of Dealer]:[Type of Dealer] , "Merchant")
You need a comma between the range and the criterion, and there is no need for the equal sign.
Does that solve your problem?
Darren Mullen, join the Smartsheet Guru Elite
Get my 7 Smartsheet tips here
Author of: Smartsheet Architecture Solutions
-
@Darren Mullen - thanks for the suggestion but that didn't work. Here is the updated formula -
=COUNTIFS(Date:Date, AND(@cell <= TODAY(), @cell > TODAY(-15)), AND([Type of Dealer]:[Type of Dealer], "DAP Dealer", [Type of Dealer]:[Type of Dealer], "Merchant"), [New / Existing]:[New / Existing], "New", [Activity Type]:[Activity Type], "Onsite")
I am now receiving #INVALID DATA TYPE.
-
I hope you're well and safe!
Try something like this.
=COUNTIFS(Date:Date, AND(@cell <= TODAY(), @cell > TODAY(-15)), [Type of Dealer]:[Type of Dealer], OR(@cell = "DAP Dealer", @cell = "Merchant"), [New / Existing]:[New / Existing], "New", [Activity Type]:[Activity Type], "Onsite")
Did that work/help?
I hope that helps!
Be safe, and have a fantastic weekend!
Best,
Andrée Starå | Workflow Consultant / CEO @ WORK BOLD
✅Did my post(s) help or answer your question or solve your problem? Please support the Community by marking it Insightful/Vote Up, Awesome, or/and as the accepted answer. It will make it easier for others to find a solution or help to answer!
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.
-
Morning! That worked. Thank you so much for your help
-
Excellent!
You're more than welcome!
✅Remember! Did my post(s) help or answer your question or solve your problem? Please support the Community by marking it Insightful/Vote Up/Awesome or/and as the accepted answer. It will make it easier for others to find a solution or help to answer!
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
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.9K Get Help
- 441 Global Discussions
- 139 Industry Talk
- 471 Announcements
- 4.9K Ideas & Feature Requests
- 129 Brandfolder
- 148 Just for fun
- 68 Community Job Board
- 496 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 300 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!