I have this report and the data that feeds it comes from this query at the bottom of the page.
I want a report to prompt the user at run time with a date picker that will
select the records based on how this field "CONVERT(VARCHAR(64),rp.ProcessStarted,101)"
matches the date selected in the date picker. Currently my query is hardcoded with a date.
SELECT rp.ReportProcessID AS [Ticket Number],
u.LastName + ', ' + u.FirstName AS [Contact],
rp.ProcessTitle AS [Description],
ISNULL(u3.FirstName + ' ' + u3.LastName,'[none]') AS Submitter,
ISNULL(u2.FirstName + ' ' + u2.LastName,'[none]') AS Resolver,
CONVERT(VARCHAR(64),rp.ProcessStarted,100) AS Started,
[dbo].GetTaskAssignments(t.TaskID) AS Assignments,
rp.Result AS Status,
im.Priority,
ISNULL(im.merged_classification_text,'-') AS Category
FROM (ReportProcess rp JOIN ServiceDeskIncidentManagement im ON rp.SessionID = im.session_id)
-- LEFT JOIN ReportProcessComment rpc ON rp.SessionID = rpc.SessionID
LEFT JOIN [User] u2 ON u2.UserID = im.resolved_by_user_id
LEFT JOIN [User] u3 ON u3.PrimaryEmail = im.submitted_by
JOIN Task t ON rp.SessionID = t.TrackingID AND t.IsCompleted = 'False'
LEFT JOIN
(ReportProcessContact rpct JOIN [User] u ON rpct.ReferenceID = u.UserID)
ON rp.SessionID = rpct.SessionID
WHERE CONVERT(VARCHAR(64),rp.ProcessStarted,101) = '11/17/2013'
AND rpct.IsPrimary = 'True'
ORDER BY rp.ReportProcessID