Dashboards & Visualizations

Remove \ at the end of field values

marco_massari11
Communicator

Hi,

I have some syslog logs and for a field those possible values:

myfield=sjhfshgfjwes\

myfield=abah\

myfield=dshaese\

 

I have a query tho show the result in a column chart:

index=myindex site=* myfield=*

| chart count by site myfield

 

When I click on a bar, I have another dashboard that shows some informations for the specific myfield, but I have an error  "Unbalanced quotes", I think for the final \. How can I remove \ at the end of the field values?

 

Thank you in advance

Labels (5)
0 Karma
1 Solution

richgalloway
SplunkTrust
SplunkTrust

Try this.

... | eval myfield=rtrim(myfield,"\\")
---
If this reply helps you, Karma would be appreciated.

View solution in original post

richgalloway
SplunkTrust
SplunkTrust

Try this.

... | eval myfield=rtrim(myfield,"\\")
---
If this reply helps you, Karma would be appreciated.
Get Updates on the Splunk Community!

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer Certification at ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...

Share Your Ideas & Meet the Lantern team at .Conf! Plus All of This Month’s New ...

Splunk Lantern is Splunk’s customer success center that provides advice from Splunk experts on valuable data ...