Results 1 to 2 of 2

Thread: Adding a user defined date range to my reports?

  1. #1
    Join Date
    Aug 2005
    Posts
    6

    Adding a user defined date range to my reports?

    This is a pretty simple query that tracks 'yesterdays' apply clicks on our website.



    SELECT MIN(A.hitDate) AS minDate, D.AffiliateName, B.ProdType, COUNT(DISTINCT A.ipAddress) AS TOTAL
    FROM ArchiveApplyTracking A LEFT OUTER JOIN
    Configuration.dbo.Affiliates D ON A.affiliateID = D.AffiliateID LEFT OUTER JOIN
    Incoming C ON A.campaignID = C.ID LEFT OUTER JOIN
    Configuration.dbo.ProductType B ON A.productTypeID = B.ProdNo
    WHERE (A.hitDate >= DATEADD(d, DATEDIFF(d, 0, GETDATE() - 1), 0)) AND (A.hitDate < DATEADD(d, DATEDIFF(d, 0, GETDATE()), 0)) AND (A.deal = 1) AND
    (A.ipAddress NOT IN
    (SELECT ipAddress
    FROM [Tracking].[dbo].ipTracking)) AND (B.ProdType NOT LIKE 'refused%') AND (D.AffiliateName LIKE 'ARROW%') AND
    (B.ProdType NOT LIKE '%prequalify%')
    GROUP BY D.AffiliateName, B.ProdType
    ORDER BY D.AffiliateName


    No problem there, that's fine.

    But how can i put a simple date range interface on my published report so users can say "get me the stats from 04/09/2005 to 20/09/2005, which then runs the query?


    Thanks for any help

  2. #2
    Join Date
    Oct 2005
    Posts
    3
    You need create report parameter then transfer its to DataSet!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •