No announcements

### Cumulative sum based on condition using MOD

a number of helper columns to get Col -I.  Helper -1: Count 1 for everything except OFF (count zero). Helper -2: Cumulative Sum ...
| 23 Replies | 933 Views | Created by M.Awal - Sunday, July 28, 2019 10:04 AM | Last reply by M.Awal - Wednesday, August 21, 2019 11:19 AM

### cumulative sum with condition

of dosage is equal to zero when its mod by 6 then next cumulative sum of next row should start from that ...
| 3 Replies | 1609 Views | Created by pratap_17 - Thursday, March 10, 2016 6:11 AM | Last reply by Eric__Zhang - Friday, March 11, 2016 8:17 AM

### DAX - measure with a cumulative sum and a condition

countries and I'd like to add a condition to this measure that would only calculate the cumulative sum if ...
| 3 Replies | 883 Views | Created by Igor-M - Monday, August 5, 2019 6:37 PM | Last reply by Herbert Seidenberg - Tuesday, August 6, 2019 2:37 PM

### Calculating Sum Based on condition

DECLARE @martialLaw TABLE (sequence INT, length INT) INSERT INTO @martialLaw (sequence, length) VALUES (1, 10),(2, 20),(3, 30),(4, 40),(5, 50) SELECT *, (SELECT SUM
| 1 Replies | 550 Views | Created by Abhinav530 - Thursday, March 19, 2015 8:01 PM | Last reply by Patrick Hurst - Thursday, March 19, 2015 8:12 PM

### Conditional sum based on visibility

Are you using the Previous aggregate to get the previous entry? If you are not, then you can add a conditional, using the same expression for determining the visibility, to ...
| 7 Replies | 6402 Views | Created by atlayank - Monday, March 12, 2007 3:07 PM | Last reply by atlayank - Tuesday, March 20, 2007 9:57 PM

### Sum based on 2 conditions

.SellDate ... Anyway, you can JOIN both tables by the exact condition and aggregate. select T1.CustomerID, T1.CustomerDate, sum(T2.Value) as ...
| 4 Replies | 1442 Views | Created by Gilles De Rore - Thursday, December 13, 2012 1:35 PM | Last reply by --CELKO-- - Thursday, December 13, 2012 4:08 PM

### Cumulative Sum using calcuation

Hi, I used following code to generate overall cumulative sum. Sum({null:[Date].[Fiscal YMD].CURRENTMEMBER},[Measures].[Device ...
| 4 Replies | 1340 Views | Created by SoyLover - Friday, August 2, 2013 1:28 AM | Last reply by SoyLover - Friday, August 2, 2013 3:35 PM

### Sum rows based on condition

@microsoft, please verify my account For instance 702 is calculated based on sum of Category Turnover for rows ...
| 5 Replies | 721 Views | Created by Gordonik - Wednesday, July 11, 2018 10:34 PM | Last reply by Ehren - MSFT - Monday, December 3, 2018 7:01 PM

### SSRS sum values based on condition

!totaltime.Value) / 60) & ":" & RIGHT("0" & (Sum(Fields!totaltime.Value) MOD 60), ...
| 4 Replies | 1176 Views | Created by HaroldDu - Friday, September 30, 2016 2:33 PM | Last reply by HaroldDu - Friday, September 30, 2016 7:52 PM

### Sum based on group by and one condition

Isn't this the same question as
| 9 Replies | 740 Views | Created by Abhinav530 - Friday, March 20, 2015 3:16 PM | Last reply by --CELKO-- - Friday, March 20, 2015 7:16 PM

### Sum values based on condition in SSRS

Hi Akash, To sum based on condition sathya - www.allaboutmssql.com ** Mark as answered if my post solved your problem and Vote as helpful if my ...
| 9 Replies | 18925 Views | Created by Mannusanghi - Thursday, March 13, 2014 8:03 PM | Last reply by Pollop_y - Tuesday, January 14, 2020 4:41 AM

### How to calculate cumulative sum based on group by

Hi, I have a table with the data as shown and need to calculate cumulative sum based on three columns group (dtTimestamp, mode, type). Columns highlighted ...
| 2 Replies | 822 Views | Created by ABCD0008 - Thursday, November 21, 2013 8:31 PM | Last reply by ABCD0008 - Thursday, November 21, 2013 9:47 PM

### Summing Single Column Based on Condition

= ST.[Posting Date] THEN ST.Quantity ELSE 0 END) AS [On Time Shipped
| 2 Replies | 547 Views | Created by alisag09 - Tuesday, October 9, 2018 8:10 AM | Last reply by alisag09 - Tuesday, October 9, 2018 8:38 AM

### Cumulative Sum

Hi C-Sharp Mamba, Supposing you're doing a cumulative sum on the value column among the weekdays in the same week, you can reference the below ...
| 5 Replies | 734 Views | Created by C-Sharp Mamba - Tuesday, April 28, 2015 2:33 PM | Last reply by Eric__Zhang - Wednesday, April 29, 2015 6:54 AM

### condition based sum measures in MDX

counting of "deal" based on dealDate in the other column, right? In this scenario, you may use MDX function linkmember, please try ...
| 3 Replies | 840 Views | Created by Shanu_Shri - Wednesday, March 29, 2017 7:12 AM | Last reply by willson yuan - Wednesday, March 29, 2017 9:37 AM

### SUM VALUES BASED ON IIF CONDITION

I solve it using CDec(0) in the expression you can also use val() to avoid the error =SUM(IIF(Fields!ItemStatus.Value = 0, val(Fields
| 2 Replies | 834 Views | Created by wakefun - Friday, October 9, 2015 9:26 AM | Last reply by Visakh16 - Friday, October 9, 2015 12:06 PM

### Rolling up Cumulative Sum

-bi-tools/ http
| 1 Replies | 1368 Views | Created by JordanYates - Monday, August 5, 2013 8:29 PM | Last reply by ckekiass2012 - Monday, August 12, 2013 10:01 AM

### ssrs sum based upon a conditional statement

http://social.msdn.microsoft.com/Forums/sqlserver/en-US/12e2cdf4-1fd7-4f2a-ba12-ff5c4ec01eeb/sum-values-based-on-condition-in-ssrs?forum
| 2 Replies | 1221 Views | Created by wendy elizabeth - Friday, March 14, 2014 6:07 PM | Last reply by Visakh16 - Friday, March 14, 2014 7:49 PM