Skip to main content
Version: v4.24

write_xsv

Transforms event stream to XSV byte stream.

write_xsv field_sep:str, list_sep:str, null_value:str, [no_header=bool]

Description

The xsv format is a generalization of comma-separated values (CSV) data in tabular form with a more flexible separator specification supporting tabs, commas, and spaces. The first line in an XSV file is the header that describes the field names. The remaining lines contain concrete values. One line corresponds to one event, minus the header.

The following table lists existing XSV configurations:

FormatField SeparatorList SeparatorNull Value
csv,;empty
ssv<space>,-
tsv\t,-

Note that nested records have dot-separated field names.

field_sep: str

The string separating different fields.

list_sep: str

The string separating different elements in a list within a single field.

null_value: str

The string denoting an absent value.

no_header=bool (optional)

Whether to not print a header line containing the field names.

Examples