LAG() can cause a node crash?
Recently I struggled with sudden node crahses. I found out that a certain parametrization of the LAG() function was the cause. Luckily, I could restart the node with AdminTools.
I was able to reproduce the crash by using the table and sample data of chapter "Sessionization" in the docs.
It turned out that using an offset parameter other than a fixed integer produces the node crash. E.g. in the following query:
LAG(timestamp,1) doesn't crash (also value 50 wouldn't crash).
,CONDITIONAL_TRUE_EVENT(timestamp - LAG(timestamp,userId) > '30 seconds')
OVER(PARTITION BY userId ORDER BY timestamp) AS session
Is this "simply a bug" and will it eventually be fixed, or can I not use Integer valued expressions as a parameter (however, this should be possible from the docs)?