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

Announcements
Note: You may notice some temporary visual or styling issues in the Community. Our vendor is actively investigating.
cancel
Showing results for 
Search instead for 
Did you mean: 
simospa
Partner - Specialist
Partner - Specialist

Both Precedes and Follows in Set Analysis

Hi!

I'm trying to use precedes and follows in Set Analysis, and they are what I need: I saw the posts about them where @swuehl and @petter explained how to use "separately".

But I need to use them... both in the same Set Analysis for the same field.

For example: OrderNo between  'V21013238' and 'V21016423' (I set them into two variables, vOrderFrom and vOrderTo).

I tried to use:

Sum({$< [OrderNo ] = {"=[OrderNo ] follows '$(vOrderFrom)' "},
                   [OrderNo ] = {"=[OrderNo ] precedes '$(vOrderTo)' "}
>} [Amount])

but it doesn't work 😞

Any help please?

Thank you!

S.

1 Solution

Accepted Solutions
tresesco
MVP
MVP

Give a try like:

Sum({$< [OrderNo ] = {"=[OrderNo ] follows '$(vOrderFrom)'   AND  [OrderNo ] precedes '$(vOrderTo)' "}
>} [Amount])

View solution in original post

2 Replies
tresesco
MVP
MVP

Give a try like:

Sum({$< [OrderNo ] = {"=[OrderNo ] follows '$(vOrderFrom)'   AND  [OrderNo ] precedes '$(vOrderTo)' "}
>} [Amount])

simospa
Partner - Specialist
Partner - Specialist
Author

Thank you, it works!

I was not so far, but your solution is perfect!

S.