Navigation
Synopsis Functions for reading and writing Comma-Separated Values (CSV) files.
Usage import lang::csv::IO;
Description The CSV format is used for exchanging information between spreadsheets and databases. A CSV file has the following structure:
  • An optional header line consisting of field names separated by comma's.
  • One or more lines consisting of values separated by comma's.

    The following functions are provided:
    • generate:
    • readCSV: Read a relation from a CSV (Comma Separated Values) file.
    • writeCSV: Write a relation to a CSV (Comma Separated Values) file.
Examples
field_name1,field_name2,field_name3
aaa,bbb,ccc CRLF
zzz,yyy,xxx CRLF
Is this page unclear, or have you spotted an error? Please add a comment below and help us to improve it. For all other questions and remarks, visit ask.rascal-mpl.org.