简体   繁体   中英

ASA Lag is returning a result from outside given duration

I try to use Azure stream analytics to filter results that are too far from the last 2 reads. However, if last read is more than 720 minutes back (by reading time) I don't want to discard current read because of this difference.

I noticed the following is returning a read from 900 minutes back, which is unexpected as far as I can understand:

LAG(Reading,2) 
OVER (PARTITION BY RegisterNumber LIMIT DURATION(minute, 720)) 
[BeforeLastReading]

I can ignore this read in my select query but I prefer to understand the reason before give up using the duration feature...

Have you tried using the TIMESTAMP BY clause? You can find more documentation on this here: https://docs.microsoft.com/en-us/stream-analytics-query/timestamp-by-azure-stream-analytics

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM