cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Sum from 2 rows

0 Likes
806

Hello all,

I m trying to sum 2 figures in the same block base on my scenario and criteria

attached. However, I cannot get the sum results but only sum of each row not

the sum of the 2 rows together which is actually what I wanted. Would u hint

me on where to start solving this problem.

I have already put the formula in the attachment... but seems to no avail..

THe actually value I want on the HK ReClass field shud be the sum = 203270.32 + 2802491.52 = 3005761.84

I m using Webi XI 3.0 or DeskKI.

THanks

Clement






<!--

/* Font Definitions */

@font-face

{font-family:ËÎÌå;

panose-1:2 1 6 0 3 1 1 1 1 1;}

@font-face

{font-family:"@ËÎÌå";

panose-1:2 1 6 0 3 1 1 1 1 1;}

/* Style Definitions */

p.MsoNormal, li.MsoNormal, div.MsoNormal

/* Page Definitions */

@page Section1

div.Section1

-->

=If(

&lt;&gt;&quot;116875&quot; And &lt;&gt;

&quot;210976&quot; ) Then &quot;&quot;


 Else ( Sum(


 Where( InList (&quot;116875&quot;;&quot;210976&quot;))))'

Accepted Solutions (0)

Answers (8)

Answers (8)

0 Likes

Hello Ishaq and GodBlessme,

I used NoFilter (sum of balance ([dimension] where [dimension] inlist (value1, value1) )) and it works.

Former Member
0 Likes

Sum([Sum of Balance] ForAll ([Hkacctcode];[Hkbsacctname])

should work

Former Member
0 Likes

Hello Clement,

Can u please let me know how u solved this. I have a similar situation

Regards

Ishaq

0 Likes

Thank you so much for ur help! Perhaps i didnt' state clearly my problem definition.

There will be more than 2 account codes in the Hkacctcode column. therefore, if i want to

sum up only selected rows's total sales, I cant achieve this by using

because this would only bring up each row''s sum only even though I specify the criterion for summation, it didnt follow - maybe due to filters.

=Sum([Sum of Balance]

Where([Hkacctcode] InList ("116875";"210976")))

And I tried this morning agian this the following and it worked..!

=NoFilter( ( Sum([Sum of Balance]

Where([Hkacctcode] InList ("116875";"210976"))) In Report ) ; All)

I can bring individual values to row total depending on my criterion regardless of filter and summation rule.

0 Likes

</html>

I have found this solution to be working... THanks for all ur guys comments...!

Thank you so much for the help! Perhaps i didnt' state clearly my problem definition.

There will be more than 2 account codes in the Hkacctcode column. therefore, if i want to

sum up only selected rows's total sales, I cant achieve this by using

because this would only bring up each row''s sum only even though I specify the criterion for summation, it didnt follow - maybe due to filters.

=Sum([Sum of Balance]

Where([Hkacctcode] InList ("116875";"210976")))

And I tried this morning agian this the following and it worked..!

=NoFilter( ( Sum([Sum of Balance]

Where([Hkacctcode] InList ("116875";"210976"))) In Report ) ; All)

I can bring individual values to row total depending on my criterion regardless of filter and summation rule.

0 Likes

Sorry.. but i cannot see any replies while the forum shows that there are 2 replies..Would u have any ideas...?

Former Member
0 Likes

I am sorry that I do not understand your requirements clearly. But I am trying to make a guess and provide you a hint to find the answer.

I assume that you want to display the value {3005761.84} in "HK Reclass" column (both the rows). This can be achieved by using Calculation Contexts.

Just try to use Sum([Sum of Balance]) In Body

Thanks & Regards,

Mohanraj CP

http://blog.mohanraj.org

Former Member
0 Likes

Clement,

on the first formula ...

{quote]Then "" {quote}

... have you tried to use

Then 0 

When you use the double-quote I think this sets up the result to be a string type, and thus adding a string type when you want to sum will get messed up. If you keep everything as a float or integer then mathematical functions should execute properly. Just a thought, best wishes with your task.

Thanks,

John