如何在iot hub路由查询中使用“starts with”或“LIKE”子句

问题描述 投票:0回答:1

设备 ID 为“KUKU1234”

我想知道如何仅路由设备 ID 以“kuku”开头的设备 像这样的东西:

$connectionDeviceId 像“KUKU%”

但是上面抛出语法错误

azure azure-iot-hub
1个回答
0
投票
Example Query to fetch devices at Azure IoTHub:

(STARTSWITH(devices.deviceId, 'ce7da2bc-fb7d-4c95-91fc-ed02b7767de6'))

[Example][1]


  [1]: https://i.stack.imgur.com/OJtZK.png
© www.soinside.com 2019 - 2024. All rights reserved.