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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
timpoismans
Specialist
Specialist

Below()

Hi all

I might just be misunderstanding the purpose of the function, or just not seeing it, but I tried the following:

CheckIDUserIDPageAccessTimeBelow(PageAccessTime)
5024712233/01/2018 9:26-
5024722233/01/2018 9:26-
5024732233/01/2018 9:27-
5024742233/01/2018 9:32-
5024752233/01/2018 11:03-
5024762233/01/2018 11:03-
5024772233/01/2018 11:04-
5024782233/01/2018 11:05-
5024792233/01/2018 11:10-

And it just doesn't work.

CheckID is an ID generated in the script, so all rows follow on eachother (Which shouldn't even be necessary for below), but when I use Below() on my Timestamp, it just returns Null().

 

Any help would be appreciated.

1 Solution

Accepted Solutions
marcus_sommer

Instead of using the implicit/explicit only-aggregation just apply concat(Field, ' + ') to exclude a NULL (-error) in the case that there are multiple values available. Further just try it with a total, like: below(TOTAL concat(Field, ' + ')).

- Marcus

View solution in original post

9 Replies
vvira1316
Specialist II
Specialist II

Below function evaluates an expression for the # (based on offset) of record below the current record

 

https://help.qlik.com/en-US/sense/September2018/Subsystems/Hub/Content/Sense_Hub/ChartFunctions/Inte...

 

In your case you don't have an expression

 

if you want to do it in script then you may want to use peek

https://help.qlik.com/en-US/sense/September2018/Subsystems/Hub/Content/Sense_Hub/Scripting/InterReco...

dplr-rn
Partner - Master III
Partner - Master III

Try Below(Only(PageAccessTime))
timpoismans
Specialist
Specialist
Author

Even when using an expression, like Sum(), Below() still doesn't function within my table:
Below_SS1.PNG

And I read the help page, but it mentions expression or field, so I thought it would be possible without measure.

timpoismans
Specialist
Specialist
Author

Tried, but didn't work. Still gives a Null() value as result

timpoismans
Specialist
Specialist
Author

Edit:

 

Having more than one dimension and one measure in my table seems to break the Below() function:
Below_SS2.PNG

(The black line is just there to make it clear it's two tables.)

Any ideas why this is happening?

marcus_sommer

Instead of using the implicit/explicit only-aggregation just apply concat(Field, ' + ') to exclude a NULL (-error) in the case that there are multiple values available. Further just try it with a total, like: below(TOTAL concat(Field, ' + ')).

- Marcus

timpoismans
Specialist
Specialist
Author

Hi Marcus

Adding the total fixed my issue, but could you explain me just how it fixed it? I don't understand why Below() wouldn't work without it in the first place.

Thanks in advance.

 

Regards,
Tim P.

marcus_sommer

I think the reason is that below() is in general calculated against a single dimension and if there is more than one it results in missing values for some rows or even in NULL. By applying a TOTAL statement it ignores this restriction respectively treated the multiplen dimensions as a single (merged) one. I fear it's not really a good explanantion, therefore take a look here:

Missing-Manual-Above-and-Below

- Marcus

timpoismans
Specialist
Specialist
Author

It's an understandable explanation, so it works for me! 

Thanks again.