Solved

If search finds a certain word in range then add specific comment to different cell

Posted on 2016-08-31
11
44 Views
Last Modified: 2016-09-01
How do I modify this so that it searches a range not single cells? So for example instead of AV2, I would like the range of AV:AZ to be searched for the word "A9270". Same for Fluoride.  Is it also possible to use Floride, Oral, Dental, Tooth. Any one of these could appear in a range. Then what would happen is the comments in the "" if match word is found will be added in a different column.

=IF(ISNUMBER(SEARCH("A9270",$AV2)),"A9270 By definition this is a HCPCS for non-covered services. Need instruction on benefit response.  Authorization has this code.", IF(ISNUMBER(SEARCH("Fluoride",$AV2))," Analysis required. Claims with Dental codes.","Analysis Required"))
0
Comment
Question by:Culwatrnca11
  • 6
  • 4
11 Comments
 
LVL 25

Expert Comment

by:ProfessorJimJam
Comment Utility
try this formula. it must be entered with control shift enter. becuase it is an array formula

but i suggest you use excel tables instead of whole column reference in AVto AZ

here is the formula

=IF(ISNUMBER(SEARCH(AV:AZ,{"A9270","Floride","Oral","Dental","Tooth"})),"Analysis Required","not required")

if any of those texts found in that AV:AZ then it will return analysis required and if not found then it will return not required.
0
 
LVL 28

Expert Comment

by:Subodh Tiwari (Neeraj)
Comment Utility
You may try something like this......

=IF(COUNTIF($AV:$AZ,"*A9270*"),"A9270 By definition this is a HCPCS for non-covered services. Need instruction on benefit response.  Authorization has this code.", IF(COUNTIF($AV:$AZ,"*Fluoride*")," Analysis required. Claims with Dental codes.","Analysis Required"))

Open in new window

0
 

Author Comment

by:Culwatrnca11
Comment Utility
Neeraj,

Your version is working for my situation, how would you modify it to include multiple criteria? Fluoride, Dental, Oral, Teeth. Any one of these could appear in the range.

=IF(COUNTIF($AV:$AZ,"*A9270*"),"A9270 By definition this is a HCPCS for non-covered services. Need instruction on benefit response.  Authorization has this code.", IF(COUNTIF($AV:$AZ,"*Fluoride*")," Analysis required. Claims with Dental codes.","Analysis Required"))
0
 
LVL 28

Accepted Solution

by:
Subodh Tiwari (Neeraj) earned 500 total points
Comment Utility
Do you want to return the same statement if any cell in the range AV:AZ contains a string with either Fluoride or Dental or Oral or Teeth?
If so, you may try this.....

=IF(COUNTIF($AV:$AZ,"*A9270*"),"A9270 By definition this is a HCPCS for non-covered services. Need instruction on benefit response.  Authorization has this code.", IF(SUM(COUNTIF($AV:$AZ,{"*Fluoride*","*Dental*","*Oral*","*Teeth*"}))>0," Analysis required. Claims with Dental codes.","Analysis Required"))

Open in new window

0
 

Author Comment

by:Culwatrnca11
Comment Utility
yes same statement as fluoride, even if dental, oral or teeth are found.
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 28

Expert Comment

by:Subodh Tiwari (Neeraj)
Comment Utility
Then the suggested formula would work for you.
0
 

Author Comment

by:Culwatrnca11
Comment Utility
Neeraj,

Worked perfectly..  Thank you very much.  can you tell me what the * means or does?

,{"*Fluoride*","*Dental*","*Oral*","*Teeth*"}))>
0
 
LVL 28

Expert Comment

by:Subodh Tiwari (Neeraj)
Comment Utility
* is a wildcard character. e.g. in *Fluoride* means there maybe some characters before Fluoride and after Fluoride.
But if your cells contain only Fluoride, you may remove the * from the formula.
0
 
LVL 28

Expert Comment

by:Subodh Tiwari (Neeraj)
Comment Utility
You're welcome. Glad to help.
0
 

Author Comment

by:Culwatrnca11
Comment Utility
Thank you for explaining... makes sense now. take care
0
 
LVL 28

Expert Comment

by:Subodh Tiwari (Neeraj)
Comment Utility
You're welcome.
Thanks and you too.
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

INDEX and MATCH can be used to great effect to replace HLOOKUP and VLOOKUP as it does not have the limitation of needing the data to be sorted so that the reference value is in the first column or row. It also has the ability to perform a bi-directi…
Drop Down List with Unique/Distinct Values (Part II - ComboBox or ListBox and Data Validation List Bonus!) David Miller (dlmille) Intro This article focuses on delivering unique, sorted lists to list objects (e.g., ComboBox, ListBox) and Dat…
This Micro Tutorial will demonstrate on a Mac how to change the sort order for chart legend values and decrpyt the intimidating chart menu.
This Micro Tutorial demonstrates in Microsoft Excel how to consolidate your marketing data by creating an interactive charts using form controls. This creates cool drop-downs for viewers of your chart to choose from.

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now