I have a query that is trying to pull the last result of a test, the column with the result has blank results rows, so I need to exclude anything that is blank. this is the query as it stands right now, it tends to lag for long periods of time, so there is something wrong with it.
SELECT dbo_wo_A1C_.person_id, dbo_wo_A1C_.A1C_result, dbo_wo_A1C_.create_timestamp, dbo_wo_A1C_.enc_id
FROM dbo_wo_A1C_
WHERE (((dbo_wo_A1C_.create_timestamp)>=#3/30/2014# And (dbo_wo_A1C_.create_timestamp)=(SELECT MAX(create_timestamp) FROM dbo_wo_A1C_ AS T2 WHERE T2.person_id = dbo_wo_A1C_.person_id AND T2.A1C_result > 1)));
Patty
__._,_.___
Posted by: pattykf@cox.net
Reply via web post | • | Reply to sender | • | Reply to group | • | Start a New Topic | • | Messages in this topic (1) |
.
__,_._,___
Tidak ada komentar:
Posting Komentar