0

I would like to use the variable settingName for the dynamic json property. How can i accomplish that?

let settingName = 'LaunchNext';

DSEvents
| where  Timestamp > ago(1d) and Data contains (settingName)
| summarize count() by tostring(parsejson(tostring(Data.Settings)).LaunchNext.value)

I want to substitute the variable instead of the actual property

parsejson(tostring(Data.Settings)).LaunchNext.value

4

1 回答 1

0

将变量包含在[]为我工作

tostring(parsejson(tostring(Data.Settings)).[settingName].value)
于 2017-04-01T02:42:32.950 回答