View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Michael Michael is offline
external usenet poster
 
Posts: 791
Default Need help with formula to search and compare data in different col

Greetings!

I need help writing a formula to search through columns of data in two
spreadsheets, compare some values in each of the spreadsheets, and identify
any unpaired records.

Situation:

I have two spreadsheets that deal with the same entities.

In the first spreadsheet, I have 4 columns that make up a unique record:

PWSID (alpha num)
PWS Name (alpha num)
Facility Name (alpha num)
Approved Date (date)

In the second spreadsheet, I have 5 columns that make up a unique record:

PWSID (alpha num)
PWS Name (alpha num)
Facility Name (alpha num)
Actual Date (date)
Original Date (date)

What I need to do is the following:

For each unique record in the first spreadsheet, search the second
spreadsheet to find any records that match the following criteria:

1) PWSID and Facility names are identical; and 2) Either of the following is
true: " approved date" in the first spreadsheet is +/- 2 days from "actual
date" or "original date" in the second spreadsheet.

For each record in the first spreadsheet, if it finds a record in the second
spreadsheet that meets the search criteria, I would want an 'OK' to be placed
in the first spreadsheet (new column). If the search does not find a record
in the second, it should return 'No Record Found'.

Any help folks could provide would be greatly appreciated!



--
Michael