Thursday, 14 June 2012

Uses of strip line in SSRS to indicate today's date

hi to all,
 here i am posting a report which will indicate today's date by aline . this kind of reports is implementing in those data which will have a dead line target value .
 so i wrote a simple query which will show u 5 days befor and 5 days after of current date
 the query is :

DECLARE
 @table TABLE (dates datetime) DECLARE @a int
SELECT
 @a = - 5 WHILE (@a != 6) BEGIN DECLARE @dat datetime
 SELECT
 @dat =(SELECTDATEADD(DAY, @a, GETDATE()))
 INSERT
 INTO @table VALUES (@dat)
 SELECT
 @a = @a + 1 END
 SELECT
 CONVERT(VARCHAR(8), dates, 3) AS [DD/MM/YY]
 FROM
 @table
then i took a bar chart. i put the value in x axis. in the properties window u wil get strip line there i configure as i mentioned in the figure

 afetr that report look like below.






.. please try it its a very simple interview queston also ,

thanks& regards
sitakanta

  

No comments:

Post a Comment