问题描述
我正在尝试学习 KQL 并且有一个查询,我想从 Windows 事件代码 4624(登录)和 4634(注销)中获取 2 个值,并针对我仍在尝试构建的不同场景返回它们。
但主要我只想能够返回表中的值(打印或项目?)
let login = SecurityEvent
| where TimeGenerated > ago(1h)
| where EventID == '4624'
| project loginTime = TimeGenerated;
let logout = SecurityEvent
| where TimeGenerated > ago(1h)
| where EventID == '4634'
| project logoutTime = TimeGenerated;
print login
我得到的错误是“'project'运算符:无法解析名为'login'的标量表达式”
我希望看到的是:
loginTime | logoutTime
----------------------------------------------
01/02/2021 18:46:30 | 01/02/2021 18:45:45
01/02/2021 18:47:30 | 01/02/2021 18:47:45
01/02/2021 18:48:30 | 01/02/2021 18:48:45
加入会更好吗?它在同一个表 (SecurityEvent) 中,所以我认为可以这样做吗?
数据集来自 MS 提供的 Azure 门户:https://portal.azure.com/#blade/Microsoft_Azure_Monitoring_Logs/DemoLogsBlade
感谢您的帮助!
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)