cuok
Programmer
- Dec 24, 2001
- 201
Hi friends!
DatePart("yyyy",[A].[DateCheck])=DatePart("yyyy",Date())
I know that this is the criteria to get 2003 which is this year, but how i can get the past year 2002?
down this post is the whole query i want to use to get the records if present in at least one time in past year.
I tried many options of -1 and using A.DateCheck)=(select max(datecheck)
with no success
DatePart("yyyy",[A].[DateCheck])=DatePart("yyyy",Date())
I know that this is the criteria to get 2003 which is this year, but how i can get the past year 2002?
down this post is the whole query i want to use to get the records if present in at least one time in past year.
I tried many options of -1 and using A.DateCheck)=(select max(datecheck)
with no success
Code:
SELECT A.Id, A.DateCheck, A.Tobramycin, A.Ciprofloxacin, A.Meropenem
FROM Tbl_SputuomCulture AS A
WHERE (((A.DateCheck)=(select max(datecheck)
from Tbl_SputuomCulture B
where A.id = B.id and DatePart("yyyy",[A].[DateCheck])=DatePart("yyyy",Date() ))));