Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Set analysis

Hi All, nedd help, i have a table :

AbonementIDAbonementEndDate
12013.03.03
22013.03.04
32013.03.06
42013.02.04
52013.02.05
62013.04.06
72013.02.07
82013.03.08
92013.03.09
102013.04.10
112013.04.11
122013.06.12

i need 2 set analysis, one: i need count all active abonements at the start of month, for examp: at 1 of march i have 9 active abonements,

second set analysis: i need count all active adonements at the month  end(march 31), expecting result =3

please help

1 Solution

Accepted Solutions
MK_QSL
MVP
MVP

1)

COUNT({<AbonementEndDate = {'$(=MonthStart(Today()))'}>}AbonementID)

2)

COUNT({<AbonementEndDate = {'$(=MonthEnd(Today()))'}>}AbonementID)

Update : Please check enclosed file of similar functionality

View solution in original post

14 Replies
MK_QSL
MVP
MVP

1)

COUNT({<AbonementEndDate = {'$(=MonthStart(Today()))'}>}AbonementID)

2)

COUNT({<AbonementEndDate = {'$(=MonthEnd(Today()))'}>}AbonementID)

Update : Please check enclosed file of similar functionality

Not applicable
Author

Thans for fast replay, correct my if i wrong, for sum its working great, but i think for count is working wrong.. its counts only those abonements ho have abonements end date at monthstart and monthend.

MK_QSL
MVP
MVP

What is your requirement?

What ID you want to count ? i.e. Only at the End of Month or Start of Month or something else?

May be I misunderstood your question.

Not applicable
Author

i need count abonement id,my requirement is: 1 set analysis, count all active abonements when we have a monthstart, by my table result would be:

AbonementIDAbonementEndDate
12014.03.03
22014.03.04
32014.03.06
62014.04.06
82014.03.08
92014.03.09
102014.04.10
112014.04.11
122014.06.12

second set analysis count all active abonements when we have a monthend, result:

AbonementIDAbonementEndDate
62014.04.06
102014.04.10
112014.04.11
122014.06.12

in my first post  the year is wrong, should be 2014, i think that is you mislead, sorry

MK_QSL
MVP
MVP

It is difficult for anyone to give you result without knowing your actual data.

Can you post your sample apps or sample data with desired output.

This will be easiest way to give you straight forward answer..

Not applicable
Author

i found solution, little modified yours set analysis  and its works:

COUNT({<Abonement.End = {">=$(=MonthStart(Today()))"}>}distinct SabID)

and

COUNT({<Abonement.End = {">=$(=MonthEnd(Today()))"}>}distinct SabID)

with my english i cant clearly explaint what i waint i think...sory and thanks for help

MK_QSL
MVP
MVP

Oh... you want to count from MonthStart and From MonthEnd...

As far as you got your answer, I am happy.

English is not a barrier to learn QlikView... Enjoy....

Not applicable
Author

one more question, is it posible to remove today() funtion from set analysis? if i want to analyse date in the past, for example, 2013 year and december month?

MK_QSL
MVP
MVP

You can remove Today() and make more dynamic like below

Considering that you have List BOX with Field Date...

You can use below ...

=SUM({<Date = {'>=$(=MonthStart(Max(Date)))'}>}Sales)