Mastering Parent-Child Row Relationships: Solving the '#INVALID DATA TYPE' Dilemma in Health Status
I am working on a sheet where I want the parent rows to reflect the health status of their child rows. I have defined four categories, which are "No Risks," "Some Risks," "Overdue / Risks," and "Canceled / Done / On Hold." I have created a formula to achieve this, but I want to establish a rule that only when ALL child rows indicate "No Risks" or "Cancel / Done / On Hold," the parent row should mean "No Risk" or "Cancel / Done / On Hold," respectively. Otherwise, the parent row should show "Some Risk," superseded by "Overdue Risk." Can someone help identify the problem and help me rework the formula, the error message is: "#INVALID DATA TYPE" when all child rows are "No Risk".
=IF(COUNTIF(CHILDREN(), "Overdue / Risks") >= 1, "Overdue / Risks", IF(COUNTIF(CHILDREN(), "Some Risks") >= 1, "Some Risks", IF(COUNTIF(CHILDREN(), "No Risks"), "No Risks", IF(COUNTIF(CHILDREN(), "Canceled / Done / On Hold") > 1, "Canceled / Done / On Hold"))))
Best Answer
-
Try this:
=IF(COUNTIFS(CHILDREN(), "Overdue / Risks") >= 1, "Overdue / Risks", IF(COUNTIFS(CHILDREN(), "Some Risks") >= 1, "Some Risks", IF(COUNTIFS(CHILDREN(), "No Risks") = COUNTIFS(CHILDREN(), OR(@cell = "", @cell <> "")), "No Risks", IF(COUNTIF(CHILDREN(), "Canceled / Done / On Hold") = COUNTIFS(CHILDREN(), OR(@cell = "", @cell <> "")), "Canceled / Done / On Hold", "Some Risks"))))
Answers
-
Try this:
=IF(COUNTIFS(CHILDREN(), "Overdue / Risks") >= 1, "Overdue / Risks", IF(COUNTIFS(CHILDREN(), "Some Risks") >= 1, "Some Risks", IF(COUNTIFS(CHILDREN(), "No Risks") = COUNTIFS(CHILDREN(), OR(@cell = "", @cell <> "")), "No Risks", IF(COUNTIF(CHILDREN(), "Canceled / Done / On Hold") = COUNTIFS(CHILDREN(), OR(@cell = "", @cell <> "")), "Canceled / Done / On Hold", "Some Risks"))))
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.8K Get Help
- 434 Global Discussions
- 138 Industry Talk
- 470 Announcements
- 4.9K Ideas & Feature Requests
- 129 Brandfolder
- 148 Just for fun
- 65 Community Job Board
- 486 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 300 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!