【问题标题】:Creating computer group in Azure LAWS with Kusto Query使用 Kusto Query 在 Azure LAWS 中创建计算机组
【发布时间】:2020-06-12 15:11:54
【问题描述】:

我正在尝试从日志分析保存的搜索中创建计算机组以进行更新管理,但无法完全弄清楚。

使用此查询时,它将列出所有名称中包含“test”的计算机。工作正常,但不完全是我想要的。

 Heartbeat
| where Computer contains "test"
| distinct Computer

但是当我想按特定名称添加计算机时,我得到了错误。任何这我怎样才能通过使用计算机特定名称来获得结果?

[

Heartbeat
| where Computer contains "test" and "test2" and "test3"
| distinct Computer

还尝试使用“or”“has”“==”,但无法正常工作。

【问题讨论】:

  • 您要列出计算机的真实姓名吗?像计算机1,计算机2?
  • 是的,我想添加真实姓名进行查询,它会将这些真实姓名列为结果
  • 您可以使用“in”运算符,请看下面的答案。

标签: azure azure-log-analytics azure-data-explorer


【解决方案1】:

请尝试in operator

示例查询如下所示:

Heartbeat
| where Computer in ("test", "test2", "test3")
| distinct Computer

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2020-06-20
    • 2014-06-02
    • 2019-08-11
    • 1970-01-01
    • 2021-09-27
    • 1970-01-01
    • 2021-01-31
    相关资源
    最近更新 更多