SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2008 Forums
 Analysis Server and Reporting Services (2008)
 Need help
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

bala2014
Starting Member

India
2 Posts

Posted - 02/20/2014 :  08:19:11  Show Profile  Reply with Quote

Hi folks,

i have to develop the Income statement report in report builder 3.0.one input parameter is company,in dropdown 18 companys will bind.if i select one company the income statement display for that company,if i select all company from filter income statement display the all 18 companys data.

i have done this sql query level,need to implement in report.


please help me on this.

bala

James K
Flowing Fount of Yak Knowledge

3699 Posts

Posted - 02/20/2014 :  13:08:30  Show Profile  Reply with Quote
That sounds like a simple report. The exact steps to create the report is rather long, so look up how to create basic reports. Your query/stored proc that returns the income statement will have one parameter, which would be a parameter for the report as well.

You can fill in the "available values" for the report with the 18 companies, or a better option, store the companies and their ID's in the database, and use the "Get values from a Query" option to fill in the company names.
Go to Top of Page

hbadministrator
Posting Yak Master

120 Posts

Posted - 02/20/2014 :  15:06:13  Show Profile  Reply with Quote
Create 2 datasets.
in the first dataset create your main table that houses all the data including the 18 companies. Then in the Where statement create a (tablename.fieldname = @company). Next create a new dataset and do a select statement with just the column that corresponds to "" company from that tablename. Once both datasets are created go to parameters and click "add Parameters", Name it Company or whatever you feel like. General tab Name the field and then the prompt and check box the Allow Multiple Values. Then select Available Values on the left. Get Values from a Query. Choose Dataset2, Value Field you will select company or the name of the field you called it and then Label Field is the same. Hit ok and then preview.


Example DataSet1
Select Company, City, State, Zip
from TestTable
Where (TestTable.Company = @company)
--------------------------------------------------------------

Example Dataset2
Select Company
From Testtable
Group By Company




Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.05 seconds. Powered By: Snitz Forums 2000