Solved

Dynamic Report

Posted on 2011-09-11
5
440 Views
Last Modified: 2012-05-12
Hello Experts,
I need to create Dynamic report,I mean I can use one report  for different tables and fields,
I need to select colums in aspx page then pass the database and function  to sql report .
How can I change field name in the report ?
0
Comment
Question by:samprg
  • 3
  • 2
5 Comments
 
LVL 25

Expert Comment

by:TempDBA
ID: 36524517
As far as I know, this is not possible with SSRS.
But still this looks achievable. Create a report that gives all the fields that is possible, with NULL values for the fields where data is not retrieved for a particular report type, and while showing in the frontend, hide the columns where datavalue is NULL.
0
 

Author Comment

by:samprg
ID: 36525061
Please Can you give more detail
0
 

Author Comment

by:samprg
ID: 36525075
Do you have any example ?
0
 
LVL 25

Accepted Solution

by:
TempDBA earned 500 total points
ID: 36527527
What I wanted to say is create a common procedure that retrives data from all other procedures and finally creates a temporary table with all the possible columns. Then select data from this table. This is because while creating a rdl, you need to finalize on the datafields which can't be produced dynamically. So, this is the way I was suggesting. This is troublesome but to create a master procedure for all as you wish, you have to do in this way only I guess.

Suppose you have three procedures which gives different results. So, now instead of creating three different reports, Create a master procedure and call all the three procedure inside, and built a temporary table with all the possible columns and fetch data from that. For the fileds which are not resutled from the procedure, by default keep the value to be NULL. Now built a rdl which will have dataset getting datafiled for all the possible ones. When you are showing your data, just hide the columns with no data. I did this for one of my report where we had  100 columns to display but everywhere data presence was not sured and the presence of data was based on some criteria. so, generally the column respect to the criteria just yields 10-12 columns with good data.

This is again an overhead for the server as you will be running the procedures unnecessarily . But based on your requirement you can even skip that.
0
 

Author Closing Comment

by:samprg
ID: 36530830
Awesome
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

Hi, In my previous Article  (http://www.experts-exchange.com/Database/Reporting/A_15199-Introduction-to-Microstrategy.html)I discussed some basic understanding of Microstrategy that how we can get in Intro of Microstrategy (MSTR). Now it's tim…
Occasionally there is a need to clean table columns, especially if you have inherited legacy data. There are obviously many ways to accomplish that, including elaborate UPDATE queries with anywhere from one to numerous REPLACE functions (even within…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now