Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I am facing issues in distributing the amount on the front end among the Buckets.
Ex: Amount to be distributed : 240
From | To | Required Amount |
0 | 100 | 100 |
100 | 200 | 100 |
200 | 300 | 40 |
300 | 99999 | 0 |
Please advise !!!
Hi,
Try with this expression
if(Sum (Values)>To, To-From, If(Sum(Values)>From, Sum(Values)-From, 0))
Hi,
What is the output you are expecting, can you come up with an example of source data and expected data.
Regards,
Jagan.
Hi Neelam, Are you looking at some sort of a histogram? Please attach something that points to the expected output. thanks.
Hi,
Thanks for the reply!
Actually the example I have mentioned in my post only. I am also attaching an application with Dummy data for reference. There,, I need to distribute the Sum(Values) over the bucket by the Difference of the Buckets.
In the application, if To - From < Sum(Values) then To, else remaining Sum(Values)
From To Sum(Values)
0 5 5
5 10 5
10 15 1
So My value is 11 which is now distributed over the Buckets based on the difference of the From & To.
Let me you if face any difficulty in understanding my explanation.
Thanks,
Neelam
Hi,
Thanks for the reply!
Actually the example I have mentioned in my post only. I am also attaching an application with Dummy data for reference. There,, I need to distribute the Sum(Values) over the bucket by the Difference of the Buckets.
In the application, if To - From < Sum(Values) then To, else remaining Sum(Values)
From To Sum(Values)
0 5 5
5 10 5
10 15 1
So My value is 11 which is now distributed over the Buckets based on the difference of the From & To.
Let me you if face any difficulty in understanding my explanation.
Thanks,
Neelam
PFA.
Hi RamKumar,
Thanks a lot for the Solution so quickly!
But actually I tried checking it by changing the values in the Data, then it started giving me incorrect result.
I am trying to change it a bit to get the correct results.
However attaching the application and data file for your reference.
Thanks Again!
Neelam
PFA.
Thanks,
Ram
Hi RamKumar,
Thanks!
I tweaked your formula a bit and got correct result.
But one scenario we left, what if the value itself falls in the very first bucket only i.e. 1,2,3 &4.
I tried but its giving the same values for all the buckets, however the values should fall into first bucket only, and for rest of the buckets will e Zero.
Attaching the file and data for your reference.
Regards
Neelam
Hi
I actually, worked on it and got the result. But I feel it has become complex and might not work on large data sets.
Feel free to share if you have any other way to accomplish this.
Thanks again for the help!
Regards & Best Wishes
Neelam