PostgreSQL Tutorial: Export Table using DBeaver

October 8, 2023

Summary: in this tutorial, you will learn how to export data from PostgreSQL tables to files in different types and formats.

You can transfer data from one database to another or export it in different types and formats:

  • CSV
  • HTML
  • XML
  • TXT
  • JSON
  • Markdown files
  • SQL statements
  • Source code arrays

The process of exporting data follows a similar procedure for the supported formats. Therefore, in this guide, we will focus on the data exporting process using the CSV format.

Select the table or tables you want to export. In the context menu, choose Export Data.

img

Note: you can also export data from custom SQL query results. To do that, choose Export data in the results context menu.

In the window that appears, choose CSV and click Next.

img

Set your data extraction options (how the data will be read from the tables). This may affect the extraction’s performance. And set the export format option. They are specific to the data format you chose in step 2:

img

Set options for output files or clipboards. Note: Timestamp pattern is used here to target the file name pattern:

img

Review what you want to format and which format you will export. You can also save all your settings as a task in this step or change the task variables:

img

Press finish. See extraction progress. You can keep working with your database during the export process as the extraction will be performed in the background.

img

See More

Migrate table data with DBeaver

Import Data using DBeaver

Export Table to CSV file

Merge Data using DBeaver