Calling SSRS report from another report - ssrs-2008

I an new to working with SSRS and creating reports.
I have created a simple 1 page report from one datasource and 6 detasets.
Report takes one parameter: EmployeeId -- and generates 1 page report for that employee.
So far all good!!
Now, I want to create another report which takes a DepartmentId. This report should generate report for all x number of employees in the department and have x number of pages.
Is there any way I can reuse the report I created earlier (the one with EmployeeId as parameter) to generate the later report I described?
Thank you :)

You could probably use a subreport, if the DepartmentId is available per Employee (i would assume it is) then that would probably be your best bet

How about you inclue the employees department ID on the detail report for the Employee, then you put an action on this field and set as target the department report. Passing the clicked Department ID to the department report and you got a nice solution.

Related

pass field value to subreport or list

I'm working with jasperreport 6.5.1, I wanna display in each page the employee details and the list of the visited addresses.
I have 2 tables employee {id, name, firstName...}andvisited_addresses{id, name, id_emp...}
I tried firstly to use a jasper sub_report element but I didn't found how to pass the id of the employee who I wanna get his visited addresses
then I tried to use the list element, but I'm struggled with the same problem.
How can I pass the id field to my sub_report or my list?
It is possible to select the employee id with the query in your main report and then add it as parameter to the subreport.
The solution explained here - the version of iReport should not make a difference.
Basically it says:
Click on sub report. in the properties section got to parameters. and add the parameters which you want communicate through main report to subreport.

Repeat main report rows per each subreport row

I have a JasperReports's report already implemented using below data structure which prints a main record along with its subreport records. The main and the subreport are placed in the same detail band and the subreport uses the JRBeanCollectionDataSource($F{employees}) as its data source expression $F{employees} being the collection field on the main report data type Company.
Company
Name
Location
Employees
Employee
ID
Fullname
etc.
The question is if there is an option in report to repeat the main report columns (Name, Location..) for each subreport record I have for a certain Company?
Basically, I need repeated records in the main report.
I know this is ugly and may look pointless but that is the Business Requirement! Most importantly, I don't want to touch the existing data structure as it's more complex in real case than my example.
Any hint (could be even a hack in JasperReports) is highly appreciated.
Note: I'm using iReport 3.7.3 editor.

Multiple Reports with one call/in one PDF

I am just new with Jasper Reports and build two reports like:
First one: Gets as Parameter an Employee-Id and displays all employee details.
Second one: Gets as Parameter a Salery-Id and displays all salery details for a month.
Now I am trying to generate a Report that has as first page the employee details and than all salery reports for all month the employee has worked (and got money...).
So I set "Summary on a new page" to my employee report and add salery report as subreport in summery band.
But how do I call the salery report several times? I assume, I have to get all salery-Ids for the employee and pass them to salery report, but how?
Or am I completely on the woodway to do so?!

How to pass to a subreport the current element being iterated in iReport?

I have a report and a subreport.
How can I pass to my subreport an information of the current element being "iterated" in my master report so that it will populate the query of my subreport?
Example:
I have in my problem an Auction. An auction has a set of Product.
These products will populate the master report. But a Product has another information that I want, which is Company (the company who bought it).
So what I want to do is:
My master report will have a query selecting the Products from a given Auction.
The report must have a subreport that contains other information about each product. How can I give the ID of the current product to the subreport so that it can be populated?
-> Master report: selects Products from the Auction. (is working fine ^^)
-> Subreport : for a given Product (passed by the master report), create a report.
Thanks in advance =D
I found out a way of doing this (pretty logic)..
Just pass to the subreport the field of the datasource being used. Thus, When it iterates in the Detail field, it will get the values of each element in your query.

How to display individual reports in cyrtal reports

I am new in using crystal reports. I already tried to create a report but it doesn't look like what I wanted. What I want to create is an individual report of each employees where it displays their information like name, age, birth date, address, etc.. But then, crystal reports will display all reports of each employees in a single document. Is there any way that I could make each employees information to display in a single document like I could use an arrow to navigate to next employee information if I want to see their report?
By the way, I used Microsoft SQL R2 in getting data for my reports. Thanks.
hi the question is not clear..as my knowledge i suggest..that if you design
the crystal report of one employee in single document and attach stored procedure to that
report your problem is solved ..you will get every employee details in a serial order this is the answer if i understand your question correctly,if not can you please repeat the questi
on with changes which i can understand
thank you