Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

set analysis error

Hello all,

I need help on indirect set analysis. I am currently using v9

[ code ]sum(<Year={"$(=max(Year))"}>,Customer=p({<Year={"$(=max(Year)-1)">}})Sales)/code ]


it should return this year's sales for customers who had sales last year, but I am having syntax error!

Thanks for help

Ryan

Labels (1)
1 Solution

Accepted Solutions
Oleg_Troyansky
Partner Ambassador/MVP
Partner Ambassador/MVP

See attached. A couple of brackets were missing. The working formula is:

sum( {<Year={"$(=max(Year))"},Customer=p({<Year={"$(=max(Year)-1)"}>})>} Sales)

cheers!

Ask me about Qlik Sense Expert Class!

View solution in original post

7 Replies
Oleg_Troyansky
Partner Ambassador/MVP
Partner Ambassador/MVP

As much as I can see, you have the two brackets switched places. Try this:

[ code ]

sum(<Year={"$(=max(Year))"}>,Customer=p({<Year={"$(=max(Year)-1)"}>})Sales)

[/code ]

Oleg

Ask me about Qlik Sense Expert Class!
Not applicable
Author

Thanks for advice, but it seems to have issues addition to that.

Oleg_Troyansky
Partner Ambassador/MVP
Partner Ambassador/MVP

can you provide any specifics? Or, even better, post an example?

Ask me about Qlik Sense Expert Class!
Not applicable
Author

I am still having syntax errors.

Not applicable
Author

Here is an example file that I actually got from QDays! I am trying to understand the code before I implement indirect set analysis to my project, but example has sytax error Sad

Oleg_Troyansky
Partner Ambassador/MVP
Partner Ambassador/MVP

See attached. A couple of brackets were missing. The working formula is:

sum( {<Year={"$(=max(Year))"},Customer=p({<Year={"$(=max(Year)-1)"}>})>} Sales)

cheers!

Ask me about Qlik Sense Expert Class!
Not applicable
Author

Thanks!