Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Analysis Server and Reporting Services (2005)
 Include field value in page header

Author  Topic 

MikeDevenney
Starting Member

20 Posts

Posted - 2008-03-11 : 09:39:46
I want to include a value from my result set in the header of my report but get the "You cannot reference a field value in the page header or footer" message. Here's why I want to do it:

The report uses three parameters: Date1, Date2 and Type. If Type is set to DATES the stored proc uses dates 1 and 2 as criteria to limit the returned records. Because Dates 1 and 2 are set in the report I can use the parameters collection to get those values and include them in the title of the report. If the Type paramter is set to MONTH, dates 1 and 2 are ignored and the stored proc determines what the dates are going to be using a UDF called from within the proc. The only way I could think of to get these calculated dates back from the proc was to insert them into the temp table it creates. Cheesy, I know... but I got the dates to the result set. Problem is I can't use them for what I need. So... to make a short question very long... how can I get the values in the result set into something I can use in the header or footer?

Mike Devenney

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-03-11 : 09:42:35
You can probably put a small table on top in report detail section and reference the values there.
Go to Top of Page

MikeDevenney
Starting Member

20 Posts

Posted - 2008-03-11 : 09:48:24
I like it... I'll let you know how it works out.

Mike Devenney
Go to Top of Page

MikeDevenney
Starting Member

20 Posts

Posted - 2008-03-11 : 09:54:58
quote:
Originally posted by visakh16

You can probably put a small table on top in report detail section and reference the values there.



Like a glove!

Thanks again!

Mike Devenney
Go to Top of Page
   

- Advertisement -