.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
david stephan
Gaurav Pal
Post New Web Links

MDX Grand Totals

Posted By:      Posted Date: October 07, 2010    Points: 0   Category :Sql Server

I asked this question a while back and got a response at the time from Javier that I thought would do the job - and it does to a degree - but I need a more dynamic approach....

Its to do with always using the subtotal for a calculation of the currently expanded dimension - rather than the total for the row..

Here is my problem....

I have a calculation that basically just divides faults by machines to give me a faults per machine figure...

For example - see the below data...


Fault Area Description Machine Builds Count Inspection Failure Count Faults Per Build (Total Builds)

View Complete Post

More Related Resource Links

overriding "grand totals" for calculated members

hi all, is there a workaround for overriding "grand totals" for calculated members?  (I cannot use the workaround whereby I create the calculation in the DSV or view directly due to it being a pretty complex Descendant parent/child calculation).   thanks much for any thoughts, Cos

Grand Totals showing "Type MisMatch" error

Hi All, I have created a calculated measure using Exponential and Datediff function, and the formula is shown below. ( (EXP((DateDiff( "d", CDATE([Time].[Date].CurrentMember.PrevMember.MemberValue), CDATE([Time].[Date]. CurrentMember.MemberValue)))/365.0 * [Measures].[CD Dec Interest Rate]) -1) * ([Time].[Date]. CurrentMember.PrevMember.PrevMember,[Measures].[Cummulative_Premium])   ) In the above formula what i am trying to achieve is finding the difference between previous date and current no of days in days and dividing it by 365 and doing some multiplication after that, When i deployed above formula all my row values are getting displayed correctly but all my grand totals are displaying as "#VALUE" and when i checked the error, it displays as TYPE MisMatch. Could some one help me in finding the problem in above formula. Thanks in advance.

TopCount and grand totals

Hey all, I've written a query to show top 20 product sales. How can I also show the grand total for all product sales? Thanks, Matt

Question regarding Calculated Member Grand Totals


I have a Calculated Measure that was inherited. The logic is:



"[Time].[Time Hierarchy].[Month].&["

+ VBA!CStr(year ([ForecastMonth].[Month].

CurrentMember.Properties("Key0")) )

+ "]&["

+ VBA!Cstr(Month([ForecastMonth].[Month].


+ "]"

),[Measures].[Regular Cases])

If the [ForecastMonth].[Forecast Month].[Month] is assigned

Show grand total running total in GridView Footer

In many scenarios we need to display Running total as well as Grand total in GridView footer. In this post i will try to explain in an easy way that how we can display running total & Grand total in a GridView footer combindly. To explain this solution using an example here i use a sales order report. The report contains all sales order amount in a tabular way. I will use a GridView to display sales order amount and use GridView footer to display Running total & Grand total. Let we have a customer table with id and name column plus an orders table with OrderID,CustomerID,OrderDate & Amount. Now our goal is to show all customers order with amount as well as page wise running total & grand total. Note that running total is necessary when you enable paging in a GridView where as Grand total is always you can consider.

Vrooooom: How .NET and C# Drove an Entry in the DARPA Grand Challenge


Find out how the .NET Framework, a team of programmers, and a bunch of people from Carnegie Mellon University built an automated car to compete in the DARPA Grand Challenge. Along the way you get some inside tips on building an extensible real-time control architecture based on a whiteboard metaphor and implementing an accurate GPS-synchronized timer component for .NET.

John Hind

MSDN Magazine December 2004

Datalist with embedded Grid or List...Sub Totals issue with iteration


Let me see if one of you can assist with this one...


i have a similar situation, but mine does not use the selected item (item Command). Here is what the form is to do:


1. this is for an educational environment, so we use SID- NOT SSN's, but i use the SID as a filter in the subset as the grouping unique id.

2. I'm trying to inject a sub total row at the last line item of each SID (if more than one item in the report for that SID).

3. I'm looping thru the items in the Datalist Item Command with a for each (item i in Datalist2.Items).

Adding Totals to RDLC Matrix


I'm using a local RDLC report in VS2008 / .NET 3.5 which includes a Matrix.  It works fine and shows its corresponding Rows, Columns, and Data values as specified.

How can I add row totals / column totals in order to show sum of Data values both horizontally and vertically?

RDLC Rows and colums totals



I want to  show the row totals and column totals in the rdlc matrix. Please let me know how to do this.

For example:

                 2006  2007  2008  2009  Total

A                10      20      30      40       100

B                20      30      10      10       70  

Total          30      50      40      50       170


sum of 7 column totals in footer of gridview

I have implemented column tolals in the footer of my gridview using the technicque described in this article http://aspalliance.com/782 .Now I would like to have a total of the 7 column totals that are displayed in the footer.  Can anyone tell me how to do this.  I would like to display this in a label or an addition row in the footer if that is possible.

SSRS 2008 Toggling visibility changes the totals

SSRS 2008 When I toggle row (detail) visibility off, my subtotals are zero.  My subtotals are correct when I toggle visibility on. I am using custom aggredate functions to producte the subtotals. It appears my custom functions are not called when visibilty is off How can I work around this? Thanks in advance for your help  

Excel 2003 pivot table - parent showing grand total than the sum of its children

All, In Excel 2003, I have a product hierarchy, for simplistic sake lets say it goes A > B > C > model nbr.  I have filtered on model nbr 1.  I have the product hierarchy in my pivot table and unit cnt as the measure. Starting at level A in the hierarchy I am showing a total unit of 12000, if I drill down to B it still shows 12000, if I drill down to C it shows 100 and if I drill down to model nbr it shows me model nbr 1 with a unit cnt of 100. So my question is why are my parents not filtering the model nbr, it is taking the total for ALL records that have level A as their parent regardless of the model nbr? This does NOT happen in Excel 2007 or when I browse my cube in SSAS.

What is the best way to add an extra row to the bottom of a listivew for such things as totals, etc.

 I can add a row to the bottom of a listivew by inserting a table after the layouttemplate in a listview.  It works fine for me to call the added controls from code-behind and chane the control values. Since my listview changes width dynamically depending on the contents of the data, my added table columns don't match up.  I have tried to access the width property of the table and then match the new ones with codebhind, but it doesn't seem to work. I am simply trying to add a row to the bottom of the listview to provide for totals of the columnts.  What is the best way to to that?   Thanks

SSRS 2008 group footer totals on a new page has a non-expected large cell height

SSRS 2008 group footer totals on a new page has a non-expected large cell height. When the group total is the first component on a new page, then this happens, but when it is part of the group on but not the first component, then it reverts to normal cell height. I have played with the advance settings now for hours, but cannot get this to work. Any ideas?  

Report Builder 2.0 and Matrix Sub totals

Hi All, Hope someone can assist... I am busy building a complex Financial report and have to deal with lots of Sub Totals etc. I basically have 2 questions: 1. I have 2 Matrixes and wan't to "SUM" the sub total from one matrix with the sub total from another (both will have seperate groupings, is this even possible. 2. How do i add the Value of "TextBox1" to the value of "TextBox2", the expression will be appriciated ? Regards  

Needs totals from two unrelated tables

Hi everyone I have to create a report on reporting services that will give me 12 totals. One total has to do with a total number of tanf clients and it should be 45 but I keep getting 18, and the total number of One parent Families but I keep getting and Two-Parent Families which should be 42. then on the same report I haveto get the kids ages, Like the total kids that are age 0-3 and kids that are 4-5 and kids ta are k-12. Can anyone help with this please. I hope that made some kind of sense? All of this has to show on one report This involves Two tables that arent really related. The people_tbl and the Student_tbl People_tbl CREATE TABLE [dbo].[People_tbl]( [Parent ID] [nvarchar](50) NOT NULL, [Family ID] [nvarchar](50) NULL, [StudentID] [nvarchar](50) NULL, [Referral Location] [nvarchar](50) NULL, [Referral Date] [nvarchar](50) NULL, [Registration Date] [nvarchar](50) NULL, [Student First Name] [nvarchar](50) NULL, [Student Last Name] [nvarchar](50) NULL, [Student SS#] [nvarchar](50) NULL, [Student ____] [nvarchar](50) NULL, [Grade] [nvarchar](50) NULL, [Age] [nvarchar](50) NULL, [Student Date of Birth] [nvarchar](50) NULL, [Event ID] [nvarchar](50) NULL, [TANFreferral] [nvarchar](255) NULL, [Enrollmentstatus] [nvarchar](255) NULL, [EmailAddress] [nvarchar](100) NULL, [ScannedDocuments] [nvarchar](50) NULL, [ParentRelease] [nvarchar](50) NULL, [Stude

Gridview Totals in Footer

 I am having problems with displaying the totals in the footer of a gridview. I am writing a page whereby users can enter comments and marks for an online photo competition. The page has a details view to enter the comment and mark. Its has a details view where the photo is displayed. It has a gridview where the comments and marks that have been entered are displayed. It works well - the details view allows comment and mark entry and the gridview show the comments and marks as they are entered. The problems are twofold. Firstly the total shows double the marks that should be displayed. Secondly, when you leave the page and then return later, you have to refresh the page before it will show the latest comment and mark even though it shows this immediately after entering the data. Ive provided my code below:   Partial Class PhotoAlbum_PhotoDetails     Inherits System.Web.UI.Page     Private TotalMarks As Decimal     Protected Sub DisplayComment_RowDataBound(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewRowEventArgs) Handles DisplayComment.RowDataBound         If e.Row.RowType = DataControlRowType.DataRow Then             TotalMarks += Convert.ToDecimal(DataBinder.Eval(e.Row.DataItem, "Mark"))   
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend