Showing posts with label subtotal. Show all posts
Showing posts with label subtotal. Show all posts

Friday, March 30, 2012

Having subtotal after specific number of rows/columns

Hi
I'm working on a Matrix report in which i have a column grouping. I
have added a subtotal for the column group. so this total comes as he
last column i.e. after all the values in that column grouping. I want
to have a subtotal after lets say 10 columns and then again a total at
the end.
Can somebody tell me how to have a subtotal in the middle of a group as
well as in the end of the group?
Ankur MehtaAnkur,
The only way I know how to do this is to add another group which breaks down
your columns into sets of X number, depending on what other factor you use to
group on. Example using the Adventure Works sample database: Group on the
main Products, then do a group on Accessories under the products. Then you
can have a group2 footer which subtotals on the second group and a group1
footer which subtotals on the entire Products line.
Sorry I don't know of another way.
Catadmin
--
MCDBA, MCSA
Random Thoughts: If a person is Microsoft Certified, does that mean that
Microsoft pays the bills for the funny white jackets that tie in the back?
@.=)
"Ankur Mehta" wrote:
> Hi
> I'm working on a Matrix report in which i have a column grouping. I
> have added a subtotal for the column group. so this total comes as he
> last column i.e. after all the values in that column grouping. I want
> to have a subtotal after lets say 10 columns and then again a total at
> the end.
> Can somebody tell me how to have a subtotal in the middle of a group as
> well as in the end of the group?
> Ankur Mehta
>

Friday, March 9, 2012

Hardcode subtotal

Hello,

Can I hardcode matrix subtotal?

For instance, I want to hardcode "100%" in the following Sales report:

2007 Year

Quantity

Phones 21%

Notebooks 30%

Total 100%

Please don't ask me why I need to do that, it's a complex MDX query and the report is much more complex than I depicted.

I just need to statically write 100% in subtotal.

Write the following expression

Code Snippet

=100 & "%"

in the text box where u want to display 100%.

Best Regards,

Rajiv

|||

RajivDotNet wrote:

Write the following expression

Code Snippet

=100 & "%"

in the text box where u want to display 100%.

Best Regards,

Rajiv

I would just like to mention the InScope function. If you have a calculation in that column to determine the percentage, you can just add an IIf and InScope function to the expression to determine whether you are within the bounds of your row group, if you are within bounds then do your normal percentage calculation, if you are out of bounds then just return "100" (and use the code p0 in the Format property so that things are formatted correctly when exported to Excel).

|||

Dear Rajiv and Sluggy,

Thank you very much for your quick response.

Your approach worked!