03 Nov 2023 03:17 PM
Hey team how would I convert a "content" string field into JSON object? The Content field is a "stringified" JSON object, is there a DQL command that would convert this into a JSON object. stdout F preludes the JSON object which is what I believe is causing Dynatrace to see this content field as a string and not JSON. For comparison here is another log event structured as pure JSON
Solved! Go to Solution.
03 Nov 2023 03:42 PM
Hi @nicoe_welch
You can try if this DQL query works
fetch logs
| parse content, "DATA json:json"
| fieldsAdd appId = json[appId], level = json[level]
Basically you need to parse the content and extract the json information from the content. With using the fieldsAdd command you can add nested json fields to be visible on top level.
Best,
Sini