Need a Formula Solution

Copper Contributor

I have two worksheets of patient data in excel. Each list has patient records and one of the values in each is a patient account number. One list is those who are deceased. I need to find and match the account numbers that are in the deceased list and remove them from our main list. I tried the CountIf function but I couldn't get it to work. It would be fine if it gave me a "1" in a new column to signify a match because I can then just sort and delete any of them with a 1. But again, I couldn't get it to work. Also, the number match has to be EXACT because some would be for example 14558 and another may be 145588 and that wouldn't be a match for my case.

 

 

1 Reply

@mmestas 

Let's say the patient list is on Sheet 1, with account numbers in column A.

And the list of deceased patients is on Sheet 2, also with account numbers in column A, in A2:A1000.

 

In the first empty column on Sheet 1, enter Deceased in row 1.

In row 2, enter the formula =ISNUMBER(MATCH(A2, 'Sheet 2'!$A$2:$A$1000, 0))

Fill down from row 2 as far as needed.

You can filter the new column for TRUE, then delete the filtered rows.