Getting Data In

CSV format difference between e-mail and output

CerielTjuh
Path Finder

Hi there,

I have noticed a difference in format between the csv files generated by Splunk when e-mail the results or saving them using the outputcsv function. If I export the results to e-mail the multiline Windows events are processed as a single field with \n for new lines.

When I export the results into a field the multilines are preserved and I cannot use the csv fields in an excel sheet since Excel sees them as multiple lines. First of all did anyone notice this as well and second (even more important 🙂 ) how can i change this so that the outputcsv function works the same as the e-mail function?

Second question, could anyone tell me if it is possible to change the names of the csv files stored by the outputcsv function?

Thank you in advance!

Tags (3)

cfergus
Path Finder

Although this isn't a great answer, I have had the same problem in using output_mode=csv. Basically, my search had to remove a problem field:

curl -u xxx:yyy https://server:8089/services/search/jobs -d"search=search * | head 100 | fields - _si"

And to get the results:

curl -o ./myOutput.csv -u xxx:yyy 'https://server:8089/services/search/jobs/<sid>/results?output_mode=csv'

I don't know what the "_si" field is, but it's value has been something like "indexer-name\nindex". We are not using a summary index, so that shouldn't be the case.

I would use this as data points for a 'better csv output' support ticket.

0 Karma
Get Updates on the Splunk Community!

Community Content Calendar, November Edition

Welcome to the November edition of our Community Spotlight! Each month, we dive into the Splunk Community to ...

October Community Champions: A Shoutout to Our Contributors!

As October comes to a close, we want to take a moment to celebrate the people who make the Splunk Community ...

Stay Connected: Your Guide to November Tech Talks, Office Hours, and Webinars!

What are Community Office Hours? Community Office Hours is an interactive 60-minute Zoom series where ...