Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
Our next Qlik Insider session will cover new key capabilities. Join us August 11th REGISTER TODAY
cancel
Showing results for 
Search instead for 
Did you mean: 
souadouert
Specialist
Specialist

cumulative date

Good morning

I have a cross table, I want when I select a date, a column displays the realization --> the date of selection and a column displays the cumulative from the beginning 2017 until the selected date

thank you

1 Solution

Accepted Solutions
souadouert
Specialist
Specialist
Author

Sunny i

I used this expression, you think it is a solution does not generate problems later

=sum(if(Year(Date#(getfieldselections(SITUATION_PRODUIT), 'YYYY-MM')) ='2016'and MONTH(Date#(getfieldselections(SITUATION_PRODUIT),'YYYY-MM')) <=Month(Date#(SITUATION_PRODUIT, 'YYYY-MM')), REAL_PACKS.NOMBRE_PACK))

View solution in original post

20 Replies
Anil_Babu_Samineni

May be this?

Sum({<date = {">=Yearstart(date) <=Max(date)"}>} Sales)

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
souadouert
Specialist
Specialist
Author

anil  i want compare the year of date selection >2017   until the selected date

Anil_Babu_Samineni

May be i am not follow you, Would you provide more input on this. Better with few rows and expected result to see while selection happen

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
sunny_talwar

Are you looking to get YTD current year? What is your chart dimension?

souadouert
Specialist
Specialist
Author

for exemple sunny i selected fev 2017 , so a column displays the realisation (fevr 2017) and other column (janv+fevrier 2017)

sunny_talwar

So, MonthYear is not a dimension? You want two expressions, 1 which gives the current monthyear and the other which is YTD (Year-to-date)?

souadouert
Specialist
Specialist
Author

I will try with your method

souadouert
Specialist
Specialist
Author

hello sunny

How to extract the month of a date as yyyy-mm??

sunny_talwar

Like this

Date(MonthStart(DateField), 'YYYY-MM')