L
Linda \(RQ\)
Hello Everyone,
Using Excel 2003. I don't use excel often but have gone through a few
classes so I kind of have an idea what is possible but not a clue how to do
what I want.
My data is a list of patients sent from an access database with a list of
patients on ventilator therapy. My first goal is to show only the unique
records but uniqness is based on a couple of things.
My duplicates come when a patient has been moved from room to room. I need
to keep only the record that is the last location when the patient was on
the ventilator.
I have been doing this maually but would like to do it with a filter if it's
possible. This is how I figure it out which records to delete.
I sort by Admit number, then by ThpyStartDtTm, then by ThpyEndDtTm. If there
are duplicate records and the Start Date and End Dates are the same I have
to delete all but one record. If the start dates and end dates are a
different time frame, I keep both records because this is 2 seperate vent
cases. The way I determine which record/records to delete is to look at the
PtLocEndDtTm (Patient location). I need to keep the record for the last
location the patient was on this therapy and delete the others.
Below is an example of a record I need to filter and delete the 2
duplicates.
Fields are Pt Number, Pt. Location, PtLocEndDtTm, ThpyType, ThpyStDtTm,
ThpyEndDtTm.
1234 4BW 01/08/09 14:00 Vent 01/04/09 18:35 01/06/09 08:30
1234 ICU 01/04/09 18:30 Vent 01/04/09 18:35 01/06/09
08:30
1234 NSI 01/06/09 10:00 Vent 01/04/09 18:35 01/06/09
08:30
In this case I would delete record 1 and 2 because the vent ended when the
patient was in NSI.
Hope this can be done and I can do it because it will save me about 3 hours
a month of manual filtering.
Thanks,
Linda
Using Excel 2003. I don't use excel often but have gone through a few
classes so I kind of have an idea what is possible but not a clue how to do
what I want.
My data is a list of patients sent from an access database with a list of
patients on ventilator therapy. My first goal is to show only the unique
records but uniqness is based on a couple of things.
My duplicates come when a patient has been moved from room to room. I need
to keep only the record that is the last location when the patient was on
the ventilator.
I have been doing this maually but would like to do it with a filter if it's
possible. This is how I figure it out which records to delete.
I sort by Admit number, then by ThpyStartDtTm, then by ThpyEndDtTm. If there
are duplicate records and the Start Date and End Dates are the same I have
to delete all but one record. If the start dates and end dates are a
different time frame, I keep both records because this is 2 seperate vent
cases. The way I determine which record/records to delete is to look at the
PtLocEndDtTm (Patient location). I need to keep the record for the last
location the patient was on this therapy and delete the others.
Below is an example of a record I need to filter and delete the 2
duplicates.
Fields are Pt Number, Pt. Location, PtLocEndDtTm, ThpyType, ThpyStDtTm,
ThpyEndDtTm.
1234 4BW 01/08/09 14:00 Vent 01/04/09 18:35 01/06/09 08:30
1234 ICU 01/04/09 18:30 Vent 01/04/09 18:35 01/06/09
08:30
1234 NSI 01/06/09 10:00 Vent 01/04/09 18:35 01/06/09
08:30
In this case I would delete record 1 and 2 because the vent ended when the
patient was in NSI.
Hope this can be done and I can do it because it will save me about 3 hours
a month of manual filtering.
Thanks,
Linda