Showing posts with label scenario. Show all posts
Showing posts with label scenario. Show all posts

Wednesday, March 7, 2012

Report layout

Hey guys,

I want to create a report called "Report X", which has four reports under it. Assume the following scenario.

1. Report X

1.1. Bar chart report

1.2. Pie chart report

1.3. Matrix report

1.4. Pie chart report

In addition to this, there are about four parameters that should be available for all reports. So my question is: what approach should I follow to implement/design a report for the above requirement. Can anyone give me how to design the report layout.

Any idea is appreciated.

Thank you for your cooperation in advance.

Sincerely,

Amde

You can add the four reports as sub-reports of Report X, and pass in the four parameters from Report X to the sub-reports.|||

Hi Fang,

Thank you for your response. The thing is I don't want to use the sub-reporting concept becuase of the performance issue.And I am looking for if there is alternative way to design the report using data regions insteade of creating sub reports. As you know Data regions provide much of the same functionality and flexibility as subreports, but with better performance.

Sincerlely,

Amde

|||

If you don't want to use subreports, you can just add four dataregions - a bar chart, a pie chart, a matrix and a pie chart, one below the other, to the main report. They can use the same dataset, or you can have multiple datasets in the main report. As for the parameters, just define them on the main report level, and reference them from the individual dataregions.

Can you elaborate a little bit more on the subreport performance issue? Are you concerned with the fact that a separate query needs to be executed for each subreport?

|||

Dear Fang,

Basically, I am not that much concerned on the performance impact that sub reports would bring. I can use sub reports. However, I was just curious to know if there is an alternative way to design the report so that I can select the best one.

By the way, if I add all the four regions in the main report, can I use a list data region to put all of them in the list?

The last but not the least, I want you to provide me your suggestion on which alternative is a good approach and easy to design the report (the sub report or add all data regions in the main report?)

Appreciate your feedback

Sincerely,

Amde

Tuesday, February 21, 2012

Report from 2 tables

Hi Guys,

I am trying to build a report that will present data from 2 sql tables. Here is the scenario:

I have 2 Tbales:

1. TimeSlots - has SlotID and Time columns

2. Reserv - has SlotID, Name, Comments, Date

I am trying to build a report that will show all SlotID's from TimeSlots for a certain Day. The report should show all Time slots regardles if there is a reservation for that TimeSlot, also the Name and Comments for the Time Slot that is reserved.

The idea is that if a time slot is not reserved it should still print on the report which will then be given to the user who will manually pencil in the data should a pop up reservation occurs.

For Example:

SlotID Time Name Comments

1 6:00

2 6:15 Sven Employee

3 7:00 Randy Employee

4 7:15

Please help as i am lost!

regards

SD

You should be able to build your query something like the following:

SELECT ts.SlotID, ts.Time, res.Name, res.Comments, res.Date

FROM TimeSlots ts

LEFT OUTER JOIN Reserve res

ON ts.SlotID = res.SlotID

This will return all records in the TimeSlots table with any corresponding Reserve records based on the SlotID fields. The main thing to ensure is to uniquely identify any fields that may have duplicate names and returning duplicate field names via a subquery will throw a SQL error (just in case you weren't aware of this). You should be able to just pull the necessary fields onto your report from here.

Hope this helps.

|||

For those of you intrested, I used an Union query and build a report that groups the data on SotID!

Regards

SD