Happy Friday all! I am trying to get a report to display records either between the start and end date entered on the main form, or show all dates. Have done this a thousand times before but now Access wants to get funky (or my brain does). Here's my sql:
Code:
SELECT Members.MemberID_PK, Accounts.DBAmount, Accounts.DBDate, Accounts.Details, Accounts.CRAmount, Accounts.CRDATE, Accounts.Comments, Accounts.CheckNumber, Accounts.AsmtType
FROM Members INNER JOIN Accounts ON Members.MemberID_PK = Accounts.MemberID_FK
WHERE (((Accounts.DBDate) Between [FORMS]![MEMBERS]![SDATE] And [forms]![members]![edate]) AND ((Accounts.AsmtType) Like "*" & "monthly" & "*")) OR (((Accounts.CRDATE) Between [FORMS]![MEMBERS]![SDATE] And [forms]![members]![edate]) AND ((Accounts.AsmtType) Like "*" & "monthly" & "*"));
have also tried:
Code:
SELECT Members.MemberID_PK, Accounts.DBAmount, Accounts.DBDate, Accounts.Details, Accounts.CRAmount, Accounts.CRDATE, Accounts.Comments, Accounts.CheckNumber, Accounts.AsmtType
FROM Members INNER JOIN Accounts ON Members.MemberID_PK = Accounts.MemberID_FK
WHERE (((Accounts.DBDate) Between Nz([FORMS]![MEMBERS]![SDATE],#1/1/1900#) And Nz([FORMS]![MEMBERS]![End Date],#1/1/2199#)) AND ((Accounts.AsmtType) Like "*" & "monthly" & "*")) OR (((Accounts.CRDATE) Between Nz([FORMS]![MEMBERS]![SDATE],#1/1/1900#) And Nz([FORMS]![MEMBERS]![End Date],#1/1/2199#)) AND ((Accounts.AsmtType) Like "*" & "monthly" & "*"));
With or without a date entered I get no results. Running the query by itself gives me the "too complicated" error.
TIA! ~PEACE~