Splunk Cloud

Search Reference

Download manual as PDF

Download topic as PDF



Outputs the raw text (_raw) of results into the _xml field.

The outputtext command was created as an internal mechanism to render event texts for output.

By default, the command xml-escapes the text of events and copies them to the _xml field. If usexml=false, outputtext simply copies the text of events to the _xml field.

Since outputtext is a reporting command, the command will pull all events to the search head and cause the output to show in the statistics UI if used in the web interface.


outputtext [usexml=<bool>]

Optional arguments

Syntax: usexml=<bool>
Description: If usexml is set to true (the default), the copy of the _raw field in _xml is xml escaped. If usexml is set to false, the _xml field is an exact copy of _raw.


Example 1:

Output the "_raw" field of your current search into "_xml".

... | outputtext

See also



Have questions? Visit Splunk Answers and see what questions and answers the Splunk community has using the outputtext command.


This documentation applies to the following versions of Splunk Cloud: 7.0.8, 7.0.11, 7.0.13, 7.1.3, 7.1.6, 7.2.3, 7.2.4, 7.2.6, 7.2.7, 7.2.8, 7.2.9, 8.0.0, 8.0.1, 8.0.2001

Was this documentation topic helpful?

Enter your email address, and someone from the documentation team will respond to you:

Please provide your comments here. Ask a question or make a suggestion.

You must be logged into splunk.com in order to post comments. Log in now.

Please try to keep this discussion focused on the content covered in this documentation topic. If you have a more general question about Splunk functionality or are experiencing a difficulty with Splunk, consider posting a question to Splunkbase Answers.

0 out of 1000 Characters