azure - 合并两个具有不同列名的表 KQL

标签 azure kql azure-log-analytics

我有两个表 IdentityInfo 和 AuditLogs,因此我需要与这两列 AccountDisplayName(IdentityInfo) 和 Identity(AuditLogs) 合并。 我在微软信息中找到了这个,但没有与此问题相关的信息。

IdentityInfo
|join kind=inner AuditLogs on AccountDisplayName,[CommonField]

提前致谢!

最佳答案

假设合并意味着加入,并且列AccountDisplayName中的值与 Identity 列中的内容相等匹配,那么以下应该可以工作。

不过,您可能希望至少在 join 之一上应用过滤器/聚合。腿,取决于要连接的数据集的大小。

IdentityInfo
| join kind=inner AuditLogs on $left.AccountDisplayName == $right.Identity

join 的文档运营商:https://learn.microsoft.com/en-us/azure/data-explorer/kusto/query/joinoperator

关于azure - 合并两个具有不同列名的表 KQL,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/72454786/

相关文章:

azure - 在 KQL azure 显示器中显示今天、昨天、一周的最佳方式

azure - 如何使用Visio绘制Kusto的应用程序架构图?

azure - 在 Kusto 中解析 `key1=value1 key2=value2`

azure - 将变量存储在 Azure 逻辑应用中以在下次运行中使用

sql-server - 是否可以从本地 SQL Server 查询 Azure Active Directory?

sql - 如何添加SQL Server 2008管理员

Azure 服务 WebRole 中托管的 WCF REST 服务 : AccessControlService?

sql - 如何优化使用cte、group by并运行20+小时的SQL查询?

c# - "Control commands (starting with a dot ' 。 ') cannot be served from the query endpoint unless they are .show control commands.",

azure - Azure 应用服务日志和诊断设置之间的差异