How to remove ".": {}, from JSON? #18720
Unanswered
patrickdung
asked this question in
Q&A
Replies: 1 comment 2 replies
-
I would recommend parsing the message as JSON and then removing the field rather than doing string replacement as this is likely to be much more brittle. See an example here: |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
The program that generate the json produce something like this:
(extracted)
I would like to remove these
".": {},
How to write it in VRL in Vector?
new_message = replace(string!(.message), "\".\": {},", "")
but it complain about the period
Beta Was this translation helpful? Give feedback.
All reactions