How the heck can I achieve what I want in my query?

  • Thread starter Thread starter Sue
  • Start date Start date
S

Sue

I want to develop an expression that will alert me if either of the 2
conditions exists:
AnnualSignatures_DueDate is Past Due, or
AnnualSignatures_DueDate is approaching within the next 6 weeks.

I just know one of my Access brain friends will be able to solve this
conundrum....


Thank you
 
How do you identify that it's past due? In other words, do you reset the
DueDate once it's been accepted, or is there another field you need to check
as well?

Basically it sounds as though you want any record where
AnnualSignatures_DueDate is less than or equal to six weeks from now:

WHERE AnnualSignatures_DueDate <= DateAdd('w", 6, Date)
 
Once I've got the required sigs, I change the date to the next due date.
Sorry if I didn't give enough information.
 
I'm sorry to be so dull, but where/how do I insert this clause? In SQL? In
the design grid?

Here's my SQL statement for the query in question:

SELECT tblClient.LN, tblClient.FN, tblClient.DOB,
tblClient.[Medicaid/insurance #], tblClient.Dx_ID, tblClient.[ChartMissing?],
tblClient.[@Least1MissingNote?], tblClient.BillingComments,
tblClient.Client_ID, tblHeadsUp.BaselinePaperworkCompleted,
tblHeadsUp.InitialConsentsSigned, tblHeadsUp.CarePlanDeveloped,
tblHeadsUp.AnnualSignatures_DueDate, tblHeadsUp.AnnualSignaturesObtained,
tblHeadsUp.HeadsUpComments
FROM tblClient INNER JOIN tblHeadsUp ON tblClient.Client_ID =
tblHeadsUp.Client_ID;
 
I'm sorry to be so dull, but where/how do I insert this clause? In SQL? In
the design grid?

Either place. In the grid, put a criterion of

<= DateAdd("ww", 6, Date())

as a criterion on the DueDate field (correcting a couple of minor typos); or -
equivalently - edit the SQL of the query to

SELECT tblClient.LN, tblClient.FN, tblClient.DOB,
tblClient.[Medicaid/insurance #], tblClient.Dx_ID, tblClient.[ChartMissing?],
tblClient.[@Least1MissingNote?], tblClient.BillingComments,
tblClient.Client_ID, tblHeadsUp.BaselinePaperworkCompleted,
tblHeadsUp.InitialConsentsSigned, tblHeadsUp.CarePlanDeveloped,
tblHeadsUp.AnnualSignatures_DueDate, tblHeadsUp.AnnualSignaturesObtained,
tblHeadsUp.HeadsUpComments
FROM tblClient INNER JOIN tblHeadsUp ON tblClient.Client_ID =
tblHeadsUp.Client_ID
WHERE AnnualSignatures_DueDate <= DateAdd("ww", 6, Date());
 
Back
Top