Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Dynamic changing of row grouping using vaules from parameter

Posted on 2011-03-08
5
Medium Priority
?
844 Views
Last Modified: 2012-05-11
Hi All,

I want to change the  row grouping values(in a matrix report) dynamically depending on the values of a parameter.
For EX. I Have a column grouping for category for total price in a matrix report and i have a row grouping on States . But i want to change the row grouping from states to customers depending on the value passed in the parameter. How can i do that?

- Karru
0
Comment
Question by:skarru
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 40

Expert Comment

by:lcohan
ID: 35073871
For that you need to write a SQL SP that will take that report parameter and use it inside the SQL SP to build dynamic SQL code that you execute from there.
0
 

Author Comment

by:skarru
ID: 35074008
The fields i have taken in matrix are from a sp...so my doubt is will the report accept value from another sp for the same field?
0
 
LVL 40

Expert Comment

by:lcohan
ID: 35074042
Ok, so you should modify that SP to include the new parameter and if not null build dynamic code then execute with new group by.
0
 

Author Comment

by:skarru
ID: 35075262
This is my stored procedue can you please let me know how to modify it according to group. SP.txt
0
 
LVL 40

Accepted Solution

by:
lcohan earned 1200 total points
ID: 35083231
Please see updated attached - I changed it to CREATE and added _NEW suffix to not touch existing by accident. You may need to addapt/adjust your code but this is what I was talking about and hopefully suit your needs.
sp-new.sql
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

After much searching across the internet I have found that you could not set the name of the file you were attaching to dynamic report subscriptons in Microsoft Reporting Services. I did manage to find one article showing you how your could make a s…
Steps to solve SSRS SQL 2008 R2 User Access Control (UAC) Permission Error With the introduction of SQL Server 2008 R2 and Vista (Windows 7 as well) came new enhanced security features. One of the features included was User Access Control (UAC) t…
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…
Suggested Courses

722 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