W
woods1119
I have tried all the angles I can think of to get this query(ies) to work but
to no avail.
I have tPtData and tVisit. I need information from both tables.
From tPtData: ingPtID, strLastName, strFirstName, strFirstSeen (This is a
date mm/dd/yyyy). From tVisit: dtmVisitDate (date field), sng#MissFng,
sng#MissToe, ysnLimbLoss.
Basically, what I need to know is what persons had sng#MissFng, sng#MissToe,
ysnLimbLoss at their first visit date which is (strFirstSeen). dtmVisitDate
should match strFirstSeen. My problem is that I am getting back all of the
patient's visits, not just the dates that match each other. I have tried
different joins and no luck. I only want the information from the patient's
first visit, no subsequent visits. All visit data is stored in tVisit. The
relationship between each tables is ingPtID. tPtData's primary key is
ingPtID, tVisit has multiple primary keys (ingPtID and dtmVisitDate).
I can't figure out how to set up my query to get the result of just which
people had limb loss at their first visit.
to no avail.
I have tPtData and tVisit. I need information from both tables.
From tPtData: ingPtID, strLastName, strFirstName, strFirstSeen (This is a
date mm/dd/yyyy). From tVisit: dtmVisitDate (date field), sng#MissFng,
sng#MissToe, ysnLimbLoss.
Basically, what I need to know is what persons had sng#MissFng, sng#MissToe,
ysnLimbLoss at their first visit date which is (strFirstSeen). dtmVisitDate
should match strFirstSeen. My problem is that I am getting back all of the
patient's visits, not just the dates that match each other. I have tried
different joins and no luck. I only want the information from the patient's
first visit, no subsequent visits. All visit data is stored in tVisit. The
relationship between each tables is ingPtID. tPtData's primary key is
ingPtID, tVisit has multiple primary keys (ingPtID and dtmVisitDate).
I can't figure out how to set up my query to get the result of just which
people had limb loss at their first visit.