Qlik Community

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
Now Live: Qlik Sense SaaS Simplified Authoring – Analytics Creation for Everyone: READ DETAILS
cancel
Showing results for 
Search instead for 
Did you mean: 
sunil2288
Creator III
Creator III

For calculating the sum of Net_salesValue up to recent Gl_Period

Hi EveryOne,

I have a table having Gl_Period from 1 to 12 and ther is corresponding Net_salesValue,

I need to calculate the sum (Net_salesValue) up to the month 4 when i select Gl_Period 4 ..

Comments Awaited

Thanks

Suneel

1 Solution

Accepted Solutions
sunil2288
Creator III
Creator III
Author

hi blaze,

I want the sum (Net_Salesvalues) up to the current Gl_period i have selected.

Like If i select 4.It will be the sum of (Net_Salesvalues for Gl_period 1+Gl_period 2+Gl_period 3+Gl_period4)

Please helpme out..

Suneel

View solution in original post

13 Replies
Not applicable

Try this:

Instead of sum (Net_salesValue)

Sum({$<Gl_Period= {'Gl_Period 4'}>}Net_salesValue)

Hope this works. I apologies in advance if it doesn't. I'm new to Qlikview

sunil2288
Creator III
Creator III
Author

hi blaze,

I want the sum (Net_Salesvalues) up to the current Gl_period i have selected.

Like If i select 4.It will be the sum of (Net_Salesvalues for Gl_period 1+Gl_period 2+Gl_period 3+Gl_period4)

Please helpme out..

Suneel

Not applicable

Oh i see. Then try this

Sum({$<Gl_Period= {'Gl_Period 1';'Gl_Period 2';'Gl_Period 3';'Gl_Period 4'}>}Net_salesValue)

Hope it helps.

sunil2288
Creator III
Creator III
Author

hi Blaze,

Thanks for the Quick Reply..but i need it Dynamically...

That is the Gl_Period Should be select by the user..And in Accordance to that the corresponding Sum will be shownout..

Awaiting for response..

Thanks,

Suneel

Not applicable

sorry i cant think of anything but i'll keep trying

Not applicable

Hi Sunil,

Here i have tried a simple form of your requirement. Just like a Hint.

Not applicable

sorry but dont understand?

Not applicable

Sorry, i forgot to explain.

If you select the List Box "DateFormat", based on your selection, the Sum(Value) chart will display the total. Here i have used the date to see the value.

Hope you can understand now, but the dimension need to be checked and validate the formula. Since, it produce "error in calculation" now.

Not applicable

Mr. Sunil,

First of all, you need to have your source (Excel) data in Date format as shown below:

GI PeriodNet sales
01-Jan-105
01-Feb-1010
01-Mar-1015
01-Apr-1020
01-May-1025
01-Jun-1030
01-Jul-1035
01-Aug-1040
01-Sep-1045
01-Oct-1050
01-Nov-1055
01-Dec-1060


For facility to select month you want, define variable e.g. "Upto Date".

Link this variable with the table created in QV.

To get total sales upto selected month, you can tick "show partial sums" in presentation tab.

To get an idea, I have attached QV file.

Hope it will work for you.

Sincere Regards,

RBA