Similar Threads:
1.Comparing dates from different records
Hi,
I have a table that contains PatientNumber, EncounterNumber, AdmitDate and
DischargeDate. a Patient (and PatientNumber) may have several visits or
encounters and therefore several EncounterNumbers. I am trying to find all
records in which the admit date for a return visit by a patient is within 30
days of the previous discharge date. Here is my data:
PatientNumber EncounterNumber AdmitDate DischargeDate
100100 3040560 06/01/2009 06/03/2009
100100 4212045 06/26/2009 06/30/2009
In this instance, the admit date of the second encounter chronologically was
within 30 days of the discharge date of the previous encounter. Can someone
help with how to identify these records?
Thanks,
2.Comparing different date types in a query
Hi,
How do you use two different date types in a query?
For example, one table has a date stored as 'dd/mm/yy' but
a second table holds only 'yyyy'
I am trying to build a query that selects records where
the year (and only the year) in the two tables is equal.
Help please!
Thanks
3.Comparing Dates in 2 different Objects
I have created a query to show all of the sales for a particular group of
sales reps (leads) by date range showing customer number.
I have a second query for all of the remaining sales reps for the same date
range by customer number.
What I want to do is now find out if there were additional sales on the same
customer made on the same date or later on all of the remaining sales reps.
When I use both of these queries together in a new query, my records are
multiplying if I have more than one of the same customer in the first leads
query.
i.e. cust. # 12345 - sale for $99
12345 - sale for $110
The above sales appear 4 times if I have a match in the remaining sales rep
query.
Hope this makes sense!
Help!
4.compare 2 dates in different formats
I want to do a datedif for 2 date/times, one has the year in it and one
doesn't. I'd like to only select records where the date/times are 2 minutes
or less different. I know how to do this if I could get rid of the year in
one date field. Any suggestions?
5.Comparing date field values and deleting the earlier date record
Hi
I have a table with many duplicate records...I have used the duplicate query
wizard to select the duplicate records....I specified a duplicate as having
the same person and task assigned fields. The other field that I pulled out
into the find duplicates query result is a Date Due field (with dates in
it).....however, I want to go one step further...now that I've selected the
duplicate records into a separate query, I want to compare the date due
fields of the duplicate records and delete the record(s) with the earliest
date due date, thus leaving only the record with the most recent Date Due
date. So I want to compare one duplicate record with another duplicate and
delete the record with the earlier date due date.
Got any ideas how I can do that? Thank you for any hints, suggestions etc.
Regards
Craig
6. comparing records with same data in one field and different in ano
7. comparing records with same data in one field and different in
8. Comparing two fields in two different records