Parsing CSV/TSV Files

TIBCO Clarity can parse the source data from a CSV or TSV file according to the configured parsing rules.

Data in a comma-separated value (CSV) or tab-separated value (TSV) file is stored as tabular data in plain-text form. Plain text means that the file is a sequence of characters, with no data that has to be interpreted as binary numbers.

Procedure

  1. Click Character encoding to specify the encoding method applied to your source file. By default, UTF-8 is selected.
  2. Define how your columns are separated. Select from the following options:
    • Click Commas (CSV) if the columns are separated by commas.
    • Click Tabs (TSV) if the columns are separated by tabs.
    • Click Spaces if the columns are separated by spaces.
    • Click Custom character and enter the character used to separate columns.
      Note: Escape special characters with a backslash (\).
  3. Define which data is parsed and how it is parsed with the following options:
    Option Description
    Ignore first line(s) at beginning of file Select this option and enter the number of lines to be ignored at the beginning of the file when parsing the source data.

    You can use this operation to omit the column header.

    Parse next line(s) as column headers Select this option to parse the specified line as the column header.

    By default, this option is selected, the value is 1, which means the first row in your raw data is parsed as the column header.

    Discard first row(s) of data Select this option and enter the number of rows to be discarded.

    This operation does not discard the column header you have specified.

    Skip last rows from end of data Select this option and enter the number of rows to be omitted from the end of data.
    Store file source (file names, URLs) in each row Select this check box to create a new column that stores the name or URL of the source file.
    Use quotation marks to enclose cells that have column separators Select this check box to use quotation marks to enclose cells that have column separators.
    Store blank cells as nulls Select this check box to store blank cells as nulls.

    This check box is selected by default.

    Store blank rows Select this check box to store blank rows.

    This check box is selected by default.

  4. Click Next. Preview the source file information and click Done adding to add the source file.
  5. Optional: On the "Get data from" page, select a way to upload another source file. See Uploading Data for more details.

What to do next

Mapping Data