SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Similar Reports


Similar Reports

Author
Message
Eliza
Eliza
Old Hand
Old Hand (361 reputation)Old Hand (361 reputation)Old Hand (361 reputation)Old Hand (361 reputation)Old Hand (361 reputation)Old Hand (361 reputation)Old Hand (361 reputation)Old Hand (361 reputation)

Group: General Forum Members
Points: 361 Visits: 81
Hi,

We have many reports running that are very similar. Usually 1 column difference for example

Sales by Product
Sales by Month
Sales by Country

We don't have a data warehouse but is there any way we can use SQL to combined these three datasets efficiently but perhaps through parameters only run the chosen report?

I thought about union everything together but I think this might be inefficient and was hoping someone would have a better idea.

Many thanks
Eliza
peterzeke
peterzeke
Hall of Fame
Hall of Fame (3.8K reputation)Hall of Fame (3.8K reputation)Hall of Fame (3.8K reputation)Hall of Fame (3.8K reputation)Hall of Fame (3.8K reputation)Hall of Fame (3.8K reputation)Hall of Fame (3.8K reputation)Hall of Fame (3.8K reputation)

Group: General Forum Members
Points: 3804 Visits: 1767
Eliza:

I hate to say it, but you need to provide a little bit more information. When you say the reports differ only slightly, does that suggest that all three reports basically contain the same information (i.e., each report basically contains the same data) but merely displayed slightly differently?

Thanks,
Pete



eric.muller
eric.muller
Ten Centuries
Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)

Group: General Forum Members
Points: 1100 Visits: 1397
I think you want to do some research on something called "dynamic grouping", it will let you use the same dataset and group based on a user-selected parameter.

One good page is here, but Googling should find plenty of examples.

Cheers,
Eric
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum







































































































































































SQLServerCentral


Search