TR

Home / Guides / What Is a CSV File? Delimiter and Turkish Character Problems, Converting CSV to JSON and SQL

What Is a CSV File? Delimiter and Turkish Character Problems, Converting CSV to JSON and SQL

Updated: October 13, 2026 · AracMerkezi

▶ Open JSON ↔ CSV Converter

CSV (Comma-Separated Values) is the simplest format for storing tabular data as plain text. Each line is a record, and each column is a field separated by a delimiter such as a comma. Excel, Google Sheets, databases, and almost every programming language can read and write CSV.

A simple CSV example

name,age,city

Ayşe,30,Malatya

Mehmet,25,Ankara

The first line is the header; the following lines are records.

Comma or semicolon?

Being “comma-separated” is not universal. Excel with Turkish regional settings uses a comma as the decimal separator, so it mostly saves CSV with a semicolon. That is why, if all the data appears in a single column when you open a CSV, the problem is most likely a delimiter mismatch. The fix is to specify the delimiter explicitly or to choose the correct delimiter in the import wizard.

Quoting rules

If a field contains the delimiter, a double quote, or a line break, it is wrapped in double quotes. A double quote inside a field is doubled:

name,note

"Yılmaz, Ayşe","Said ""hello"" and left"

This rule prevents names with commas, like “Yılmaz, Ayşe,” from breaking the columns.

If Turkish characters get corrupted

If the letters “ş, ğ, ı” appear as “ç, ı” and the like, the file was saved as UTF-8 but opened with a different encoding. Excel sometimes wants a BOM (byte order mark) at the start of the file to recognize a UTF-8 file. Saving the file as “UTF-8 (with BOM)” or choosing UTF-8 as the encoding during import fixes the problem.

From CSV to JSON

Web applications usually work with JSON. The example above turns into this:

[{"name":"Ayşe","age":"30","city":"Malatya"}, {"name":"Mehmet","age":"25","city":"Ankara"}]

CSV has no type information; numbers may come through as text in the first conversion. Check the field types after conversion. For two-way conversion, use the JSON ↔ CSV Converter tool.

Markdown and HTML tables

When writing documentation, aligning a table by hand is tedious. CSV to Markdown Table produces a ready-made table with a header and separator row. To add it to a web page, CSV to HTML Table creates the appropriate <table> tags; characters such as < and & inside cells are safely escaped.

From CSV to SQL INSERT

To import a small dataset into a database, the CSV to SQL INSERT tool turns each row into an INSERT INTO table (columns) VALUES (...) statement. Single quotes in text values are doubled in accordance with SQL rules: O'Neil → 'O''Neil'.

Important warning: Always review the generated SQL before running it. Do not run commands generated from data that comes from untrusted sources directly on a production database; for large and regular imports, prefer the database's own import tools (for example, COPY or LOAD DATA).

Common mistakes

Step by step: exporting an Excel table safely

  1. Leave no merged cells or empty headers in your table.
  2. Set columns such as phone numbers and postal codes to text format.
  3. Use File → Save As → CSV UTF-8.
  4. Open the file in a text editor and look at the first lines; verify the delimiter and the Turkish characters.
  5. Before pasting into the converter, select the delimiter (comma or semicolon) in the tool.

Example: a problematic row

In a file with the header name;score;comment, the row Ayşe;90;Very good; but was late is read as four fields because of the semicolon in the comment. The correct form is Ayşe;90;"Very good; but was late". Quoting the field prevents the columns from shifting.

Which output should you choose, and when?

Before using the output, compare the row count with the source; silently skipped rows are the most common cause of data loss.

Limitations

CSV cannot carry nested structures (objects, arrays); for hierarchical data, JSON or XML is more suitable. Browser-based tools may slow down with very large files.

Frequently asked questions

When I open a CSV, all the data is in one column. Why?

There is a delimiter mismatch; Turkish Excel mostly uses a semicolon. Choose the correct delimiter when importing.

Why do Turkish characters get corrupted in CSV?

The file was saved as UTF-8 but is being opened with a different encoding; saving as UTF-8 (with BOM) or choosing UTF-8 during import fixes it.

How is a field containing a comma written?

The field is wrapped in double quotes; a double quote inside the field is doubled.

Tools mentioned in this guide

More guides

This article is for general information only and is not legal, financial or medical advice. We are not an official institution.