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

如何调整Azure Monitor工作簿自定义端点的时间范围参数格式

解决Azure Monitor工作簿时间范围参数格式问题

可以通过对参数表达式应用字符串替换函数实现格式转换,具体操作如下:

在自定义端点的URL参数中,把原表达式{TimeRange:start}替换为嵌套的replace函数调用,将默认生成的双引号格式转为单引号格式:

Created ge {replace(replace(TimeRange:start, 'datetime("', 'datetime\''), '")', '\'')}

逻辑说明:

  • 内层replace:将默认输出开头的datetime("替换为datetime'
  • 外层replace:将默认输出结尾的")替换为单引号'

处理后,原本的datetime("2023-05-23T09:30:00.000Z")会转换成需求的datetime'2023-05-23T09:30:00.000Z'格式。

Azure Monitor工作簿的参数表达式支持Kusto标量函数,这类字符串格式化操作完全可行。

内容的提问来源于stack exchange,提问作者Matthew Campbell

相关产品推荐
方舟 Agent Plan

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

最近更新时间:2026.07.20 20:52:55