Skip to main content

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
Welcome to Qlik Community! Check out our new navigation! FIND OUT MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
lauracastagna
Creator II
Creator II

ytd formula picking up ytd results

Hi,

I have the following formula that is not picking up the Financial Year Total results.  I know its in the syntax but cant see it.  where am I wrong please:-

Let vCurrentfYear = 2017;

If(Contact <> '', Count({'$Year={vCurrentfYear'} Type))

Cheers,

Laura

1 Solution

Accepted Solutions
sushil353
Master II
Master II

if you are using variable .. then in that case the value will change according to the selection.

I hope you have create the variable some thing like =Max(MonthYear)

View solution in original post

13 Replies
sushil353
Master II
Master II

Hi Laura,

Try this:  Count({<Year={'$(vCurrentfYear)'},Contact -={""}>} Type)

HTH

Sushil

balrajahlawat
Champion
Champion

What Sushil shared, should work.

You can see this as well for better understanding?

Set Analysis for certain Point in Time

Set Analysis for Rolling Periods

lauracastagna
Creator II
Creator II
Author

Hi Sushil,

I am getting a red error under the first squiggle bracket:-

 

-={" "}>} Type))

 

lauracastagna
Creator II
Creator II
Author

thank-you!!!

sushil353
Master II
Master II

It will be ok.. as this -= is not recognized by qv.

lauracastagna
Creator II
Creator II
Author

the only thing I don't like about the coding is the hard coded periods though

lauracastagna
Creator II
Creator II
Author

but it returns '0' in results

Anil_Babu_Samineni

How about this

Aggr(Count({<Year={'$(vCurrentfYear)'}>} Type), -Contact)

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)
sushil353
Master II
Master II

Try with this one

If(not isnull(Contact),Count({<Year={'$(vCurrentfYear)'}>} Type))