Showing posts with label accepts. Show all posts
Showing posts with label accepts. Show all posts

Friday, March 9, 2012

Displaying Dynamically created columns

Hello,
I have a stored procedure that accepts input parameters and depending
on the input, returns multiple columns. For example depending on the month
range passed in, the stored procedure creates and populates temporary table
with columns for each month and returns the values in the temporary table.
How do I display these dynamically created columns using Reporting Services
(the number of coulmns returned by the stored proc varies between different
runs). Any help is appreciated.Sunil,
You would need to use the matrix control and then edit the
matrix_columngroup to use the data returned from your stored proc.
Hope this helps.
Bill Youngman
Anexinet, Inc.
"Sunil Oliver" <SunilOliver@.discussions.microsoft.com> wrote in message
news:D11DBA4E-C99F-4E37-8C0D-7F9D76192001@.microsoft.com...
> Hello,
> I have a stored procedure that accepts input parameters and
depending
> on the input, returns multiple columns. For example depending on the month
> range passed in, the stored procedure creates and populates temporary
table
> with columns for each month and returns the values in the temporary table.
> How do I display these dynamically created columns using Reporting
Services
> (the number of coulmns returned by the stored proc varies between
different
> runs). Any help is appreciated.

Sunday, February 19, 2012

Display of Parameters

Hi,
I need to develop 2 reports using Crystal Reports 11. Both the reports are very similar except that one accepts 2 parameters & the other accepts only one parameter & hence their selection criteria would differ accordingly. I was wanting to know if I could merge both the reports into one, such that I use a third parameter which is boolean & asks which kind of report the user wants to see. Based on the boolean value the report needs to display either 1 parameter or both the parameters. Is this possible in crystal reports ? If not, what is the other best way I could do this ? Please suggest.Hi
Yes ur approch is right, u can do that. Make a single report and accept 3 parameters. based on parameter 1 filter ur report data in a if else condition in record selection formula.|||u can create any report based on different parameters at runtime. of course that means u have to code it in a more generic way... I have done this, bt its in vc++. I suggest u look into the sample code if u want it in vb...its not that hard...
ps: sample code is in ur crytl installed folder.|||Thanks for the responses. If i try using a 3rd parameter method, I have a problem. That is, I can filter the records perfectly fine, however when the parameter window shows up it shows all the parameters in it, the one's that the first report would use & the ones that the second report would also use. I dont want that. Based on the value of the boolean parameter, it should show the corresponding parameters for the first report & accordingly for the second. how do i achieve this ? I'm using only crystal reports....|||Thanks for the responses. If i try using a 3rd parameter method, I have a problem. That is, I can filter the records perfectly fine, however when the parameter window shows up it shows all the parameters in it, the one's that the first report would use & the ones that the second report would also use. I dont want that. Based on the value of the boolean parameter, it should show the corresponding parameters for the first report & accordingly for the second. how do i achieve this ? I'm using only crystal reports....

Hi
If u r not using any front end then u can use two seperate sub reports (on demand sub report) in main report. so number of reports are increased now.