I am trying to create a stored procedure that will allow me to search column named "AuditResults" within Access. As the StartDate and EndDate popsup to enter my date range, I would like the keyword search to popup as well so I can enter the keyword I am looking for in the "AuditResults" column. This is what I have but can't get it to work.
ALTER PROCEDURE dbo.[Proc_QryCon&RegKeywordSearch]
(@StartDate datetime,
@EndDate datetime)
AS SELECT PI, RDStudyNo, Waiverofconsent, WaiverofDocumentation, Consents, TotalSubjects, Ref#, ID, Findings, AuditResults
FROM dbo.[TblConsents&RegulatoryAudits]
WHERE (AuditResults LIKE '%') AND (Monthtoreport >= @StartDate) AND (Monthtoreport < @EndDate)
I am using SQL 2008 R2 and Access 2010.