\<bookmark_value\>number series import\</bookmark_value\>\<bookmark_value\>data series import\</bookmark_value\>\<bookmark_value\>importing; text databases\</bookmark_value\>\<bookmark_value\>delimited values and files\</bookmark_value\>\<bookmark_value\>comma separated files and values\</bookmark_value\>\<bookmark_value\>text file import and export\</bookmark_value\>\<bookmark_value\>csv files;importing and exporting\</bookmark_value\>

Opening and Saving Text CSV Files

Comma Separated Values (CSV) is text file format that you can use to exchange data from a database or a spreadsheet between applications. Each line in a Text CSV file represents a record in the database, or a row in a spreadsheet. Each field in a database record or cell in a spreadsheet row is usually separated by a comma. However, you can use other characters to delimit a field, such as a tabulator character.

If the content of a field or cell contains a comma, the contents of the field or cell \<emph\>must\</emph\> be enclosed by single quotes (') or double quotes (").

To Open a Text CSV file in Calc

  1. Choose \<emph\>File - Open\</emph\>.

  2. Locate the CSV file that you want to open.

    If the file has a *.csv extension, select the file.

    If the CSV file has another extension, select the file, and then select "Text CSV" in the Filter box

  3. Select Edit filter settings checkbox to open the Text Import dialog and set the import options for delimited data. If the Edit filter settings checkbox is not selected, LibreOfficeDev Calc uses the settings of the last text import operation.

  4. Click \<emph\>Open\</emph\>.

If the Edit filter settings checkbox is selected, the Text Import dialog opens. Then:

tip

If the CSV file uses a text delimiter character that is not listed in the \<emph\>Text delimiter\</emph\> box, click in the box, and type the character.


To Save a Sheet as a Text CSV File

note

When you export a spreadsheet to CSV format, only the data on the current sheet is saved. All other information, including formulas and formatting, is lost.


  1. Open the Calc sheet that you want to save as a Text CSV file.

    note

    Only the current sheet can be exported.


  2. Choose \<emph\>File - Save as\</emph\>.

  3. In the \<emph\>File name\</emph\> box, enter a name for the file.

  4. In the Filter box, select "Text CSV".

  5. (Optional) Set the field options for the Text CSV file.

    Select \<emph\>Edit filter settings\</emph\>.

    In the \<emph\>Export of text files\</emph\> dialog, select the options that you want.

    Click \<emph\>OK\</emph\>.

  6. Click \<emph\>Save\</emph\>.