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

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

cube total doesn't equal star total

Posted By:      Posted Date: September 29, 2010    Points: 0   Category :Sql Server

Hi.  One measure of mine is defined as a data type of money in my star.  There are many occasions where a single value can go out to 4 decimal places.  But by design the sum of this measure across the entire fact table goes to at most two decimal places.  SQL returns a sum of $1,123,219,801.94000000 when I take sum across a subselect in which the measure is cast as decimal(20,8).   When I drag the measure to my pivot area in the cube I get $1,123,219,801.09.

Why?  What are my options for consistency between the two?

My metadata for this measure in the cube shows a display format of "currency" and a source data type of "double".    

View Complete Post

More Related Resource Links

Plot Running total charts from SSAS Cube

Environment: I am using SQL Server 2008, I have installed SSIS, SSAS and SSRS. Objective: Create a Effort V/S Defect plot in SSRS 2008 Approach: 1. Created the SSAS cubes with Effort and Defects data by timeline (rollup of data based on Week ending date) 2. Created SSRS project and linked the dataset to SSAS cube. But i am unable to plot a Effort (X-Axis) v/s Defects (Y-Axis). As soon as i drag the measures into the query designer in dataset properties, the effort rollup will break. Following is the data that has been created in SSAS. I need to plot a graph of Hours v/s defects (Running total). Please guide me on how to plot the graph using SSRS 2008 from the already created SSAS cubes Week Of Hours Defects 10/24/2009 8   11/7/2009 63   11/14/2009 68   11/21/2009 80.5   11/28/2009 139   12/5/2009 221.25   12/12/2009 131.75   12/19/2009 124.5   12/26/2009 61.5   1/2/2010 73   1/9/2010 153.5   1/16/2010 149.5   1/23/2010 196   1/30/2010 163   2/6/2010 155.5   2/13/2010 178   2/20/2010 138   2/27/2010 161.5   3/6/2010 189   3/13/2010 191.9   3/20/2010 240.5 9 3/27/2010 260.2 5 4/3/2010 214.5 13 4/10/2010 274.6 24 4/17/2010 200.5 15 4/24/2010 227 9 5/1/2010 237.05 18 5/8/2010 190.5 12 5/15/2010 156.25 6 5/22/2010

same measure total differs in same cube


Hi.  Folks at http://social.msdn.microsoft.com/Forums/en-US/sqlanalysisservices/thread/4dad8e33-315e-4d36-a781-94448ce7e7ad seemed anxious to mark my finding "answered" so I'm posting here for an explanation of what seems to be a bug in ssas.

I am getting different totals in one measure group depending on whether the ssas db is first deleted before processing.  The total is incorrect if the db isnt first deleted prior to a "process full" on this measure group.  The measure involved is sourced from a money column that uses (all) 4 decimal places not just 2.  For over 300 million facts, I havent seen the error amount to more than $1.15.  But that is unacceptable in this app.

To some extent we've exhausted the money vs currency display argument.  This doesnt seem to matter if we do a full deployment after the ssas db is deleted. 

Is this a bug?  Does it only affect measures sourced by money columns?  Only if they go past 2 decimal places?  Only after a large number of deletions and a few inserts in the source star table?

Normally, this measure group processes Add.  Will I find that isnt working either?   The star source row deletio

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.

UDP Delivers: Take Total Control Of Your Networking With .NET And UDP


UDP, the lesser-known sibling of TCP, is used for DNS resolution, SNMP network status, Kerberos security, digital media streaming, VoIP, and lots more. Learn how to put UDP to work for you.

Yaniv Pessach

MSDN Magazine February 2006

Total newbie question: Calling jQuery in an UpdatePanel?



Please forgive this ignorant question - I've used ASP.NET AJAX a good deal but I'm new to jQuery.  Specifically, is it possible to call or create jQuery events on the fly via an UpdatePanel?  For example, calling a jQuery modal or animating a Label (or <div> contained Literal), etc.

If anyone has any advice or could point me to some easy tutorials on mixing ASP.NET AJAX and jQuery, I'd greatly appreciate it. 



Calculating GridView total using JavaScript/JQuery


Hello everyone.

One month ago I've had very nice conversation with a asp.net forum member asking about issue regarding calculation of GridView textboxes total using JavaScript. The main thing was to allow user to manually write values in the text boxes (placed inside GridView column) and if the value has changed automatically to perform calculation on client side.

At the end of the conversation, we came up to two solutions. The first solution was using plain JavaScript, but since I thought it was not so robust, and in order to make it more robust we would need to write few more functions. Therefore, I have simply proposed another solution using JQuery which came up much better, more robust with less code.

In this blog post I will show both of the solutions and will provide step by step explanation on how we did that.

Note: I'm using VWD.

Get cumulative total value on x-axis.

I'm currently displaying: January $200 February $100 March $400 I want to display:( i've set the custom to MMM on the axis-properties, but still the months are not getting into below required format)  Jan $200 Feb $100 Mar $400 Total $700 on the x-axis.  And i want the y-axis to be divided in the intervals of 200, but though i've set the interval as 200, it is displaying in divisions of 2000.

Calculating Full Year Total

Im creating a sales report in SSRS by pointing it at a cube in SSAS.  Im creating calculated members to aggregate my data in various ways so they can be shown on the report.   I have a FACT table containing sales figures and various dimension tables including a server created time dimension.   Ive managed to create pretty much everthing I need (e.g. Current YTD, Prior year YTD).  What I now need is a full year figure to compare current year sales to.   Below is what Im aiming for i.e. the total of 122712 from 2009 appearing against every month in 2010.   Fiscal Year Fiscal Month Count Full Prior Year sales 2009 Apr-09 9805     May-09 9942     Jun-09 8986     Jul-09 9696     Aug-09 8912     Sep-09 10097     Oct-09 11713     Nov-09 10434     Dec-09 8820     Jan-10 10821     Feb-10 11844     Mar-10 11645     Total 122712   2010 Apr-10 3517 122712   May-10 1669 122712   Jun-10 2518 122712   Jul-10 3306 122712   Ive been bashing my head against a brick wall with this one so any help would be gratefully received!

Sorting a DVWP by Column Total

I have a survey list in Sharepoint 2007, which from what I understand means I can't add a calculated column. In this survey list I have some number columns that need to be calculated for display. They are: (1) Number of Weeks, (2) Number of Hours per Week, and (3) Number of Hours for Credit. In Sharepoint Designer, I've created a Data View Web Part which displays those columns and two additional "calculated columns." Scare quotes because the calculation is happening in the XSL of the web part, not an actual calculated column. These columns are (4) Number of Hours (Column1*Column2) and (5) Eligible Hours (Column1*Column2-Column3). I have the data view grouped by @Author (Created By) and a column total row for each group. I even figured out how to get column totals for all four columns though the nodeset is grouped by Author, which breaks out of the box. Great, beautiful. The final step is sorting the entire view by the column total of Column5. In other words, I want my groups of @Authors listed in descending order by their Total Eligible Hours. Is this possible?

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.

Matrix Total Help

I have matrix report which renders as follows:                     Value category x      10 category y      5 categoy z        10 Total             25   How can i exclude category y from the total but still display its value for its row group? In other words i want Total to sum up to 20 in the above case.

Show total items for GridView in List.aspx or GridViewPager

Hi, Is there a solution to show total items in Grid View in List.aspx or GridViewPager Eg. Record: 1 - 20 of 231 

How do I create a calculated member for daily total revenue?

Hi everyone! I'm new to MDX and I can't figure out how to create a working calculated member. Here's business background: There are 2 measures in the cube - a and b. The formula for Total Revenue is a - b - $1000 ( don't ask me why =), 1000 is being subtracted from each day's Total Revenue - a ball park adjustment for something) My calculated member [Measures]. [Total Revenue] looks like this Case     When IsEmpty([Measures].[a]- [Measures].[b])     Then null     Else [Measures].[a]- [Measures].[b]-1000 Unfortunately this calculated member doesn't work correctly, it subtracts $1000 from everywhere and not from the intersection of [Dim Calendar].[HierarchyTime].[Day] and Total Revenue. How do I make it work in accordance with business logic? The objective is to adjust Total Revenue by subtracting $1000 for each day.  Thanks in advance!    

SSRS Report Group Total

I am trying to make a report in SSRS with Data source CUBE. I have a column which is calculated and inside the group. I could not take group total for that item. Please any guide my calculated column expression is =(Fields!Count_of_Passengers.Value/Sum(Fields!Count_of_Passengers.Value, "LHSH"))*100  

security top total and current level

the locig of data is Country 1 - City1 - Company1 -> Nett Income Country 1 - City1 - Company2 -> Nett Income Country 1 - City1 - Company3 -> Nett Income                                                  Total Income   How can i achive the following logic  - the user (role) Company2 have to see only Total for City 1 (Company1+Company2+Company3), just total and Country 1 - City1 - Company2 -> Nett Income I can use dimension data and check Country 1 - City1 - Company2 but in this case he/she can't see totals for City 1 any ideas ?  

running total question

I've NET_SALES Table. it's very large table.   I'm selecting couple of fields to cmplete my task.   I need to rank all invoice total by customer for every sales rep.   So sales rep ABC will have 50 custoemrs. and 1 sales rep can sell more than 1 time to 1 customer. so for ABC, MonthToDate_Rank for custoemr AAA will be 1 and total will be 1000$                  MonthToDate_Rank for custoemr AAB will be 2 and total will be 900$  For Rep ABC1 MonthToDate_Rank for custoemr DEF will be 1 and total will be 1000$                  MonthToDate_Rank for custoemr DEG will be 2 and total will be 900$   I can do it with using ROW_NUMBER() OVER(partition by rep_name order by sum(total_sale) and I've where condition which will select values only for current month. I also calculate the same with QuarterToDate_Rank, YearToDate_Rank. but all are in different rows.   Now, there is new requirement that I've to calclate everything in 1 row. So ABC rep will have customer AAA with MTD_Rank =1 , QTD_Rank = 24 , YTD_Rank = 1000   I've to calcualate everything together. Any ideas?

Sales Total, Get Curent Month

The date functions in sql is pretty complex to me. I want to get the sum of Grand Total for the current month. OrderDate is a DateTme Column. SELECT SUM(GrandTotal) FROM CompletedOrdersHistory WHERE OrderStatus='COMPLETED' AND OrderDate=@CurrentMonth;
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