You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

如何在Azure Data Explorer中查看已删除的具体化视图具体信息?

查询被删除的具体化视图名称的方法

方法1:解析操作记录的Details字段

MaterializedViewDrop操作的Details字段是JSON格式,包含被删除视图的名称,可通过parse_json函数提取:

.show operations 
| where Operation == 'MaterializedViewDrop'
| extend ViewName = parse_json(Details).MaterializedViewName
| project OperationId, StartTime, EndTime, ViewName, Details

方法2:查询集群审计日志

若集群开启了操作审计日志,直接查询审计日志表可获取明确的视图名称:

ClusterAuditLogs
| where OperationName == "MaterializedViewDrop"
| project EventTime, OperationName, EntityName, InitiatedBy, ClientIP

其中EntityName字段即为被删除的具体化视图名称。

方法3:查看数据库命令历史

如果删除操作通过Kusto客户端执行,可查询数据库的命令历史记录:

.show database <你的数据库名> commands
| where Command contains ".drop materialized-view"
| project Timestamp, Command, User

从Command字段中可直接读取被删除的视图名称。


内容的提问来源于stack exchange,提问作者Oleksandr Klunnyi

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.13 12:29:52