Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using sliding window no results output #3350

Open
wild-River2016 opened this issue Oct 31, 2024 · 1 comment
Open

Using sliding window no results output #3350

wild-River2016 opened this issue Oct 31, 2024 · 1 comment

Comments

@wild-River2016
Copy link

wild-River2016 commented Oct 31, 2024

使用滑动窗口(SLIDINGWINDOW)创建温度持续30秒大于75度的规则,没有结果输出。
规则:
select temp from stream1 group by SLIDINGWINDOW(ss,30,30) over (when temp > 75) having min(temp) > 75
测试数据:
{"deviceId":100,"temp":70.1}
{"deviceId":100,"temp":76.1}
{"deviceId":100,"temp":77.1}
{"deviceId":100,"temp":79.1}
{"deviceId":100,"temp":79.1}
{"deviceId":100,"temp":79.1}
{"deviceId":100,"temp":80.1}

Environment:

  • eKuiper version (e.g. 2.0.0):

What happened and what you expected to happen:
麻烦看一下配置规则是否正确,如何才能输出结果。
期望能得到案例集锦中(总电流持续10s超过200A)的效果。
image

@ngjaying
Copy link
Collaborator

ngjaying commented Nov 1, 2024

Having min(temp) > 75 is false. Additionally, SLIDINGWINDOW(ss,30,30) over (when temp > 75) will trigger after 30 seconds. Use SLIDINGWINDOW(ss,30) over (when temp > 75) may be what you want.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants