Rename fields name with Logstash

How to rename for clarity

Can someone kindly help with this? Thank you.

filter {
mutate {
rename => { "[test][rex-platform"\\" ]" => "[test][rex-platform]" }
}
}

Output Display Field is like this:

Table format
Column1
test.rex-platform"\

Column2
Windows"",

Welcome to the community!

How did you import data? Which input plugin? CSV perheps

Can you show us pic, screen shoot, how does exactly field look like? You can use debug

through udp

And the pic please

Here it is.

According to my tests, try with the single quotes:

  mutate { 
      rename => { '[test][rex-platform"\\" ]' => "[test][rex-platform]" }
 }

Still having the isuues

As I said, provide the debug screens from Logstash

Hello,

Yes i see with single quotes it is working

rename => { '[test][rex-platform"\]' => '[test][rex-platform]' }

Still , if issue persists please share the debug screens as requested by Rio.

Thanks!!

Thank you so much, fix the rename field. How about in the value field? It’s still Windows““,

Hello,

For value you can try to use gsub

rename => { '[test][rex-platform"\]' => '[test][rex-platform]' }
	  gsub => [
      '[test][rex-platform]', '"', '',
      '[test][rex-platform]', ',', ''
    ]

Thanks!!

2 Likes

Now fully got it. Thanks for your support.

1 Like