Easy Way to Export and Import Data in PostgreSQL Databases
In our new tutorial about how to export and import data in PostgreSQL databases with dbForge Studio.
A salient feature of the PostgreSQL Import/Export tool, built into dbForge Studio for PostgreSQL,
is that it supports file transfer between the most frequently used data formats (Text, MS Excel, XML, CSV, JSON, etc.) and allows saving templates for repetitive export and import jobs. With the tool, you can easily:
*Migrate data from other servers
*Customize import and export jobs
*Save templates for recurring scenarios
*Populate new tables with data
Enjoy simple and seamless data migration and benefit from an easy way to fill your PostgreSQL databases with external source data.
⭐️Timestamps:
00:00 Introduction
00:15 Importing data from Excel .xls file
00:32 Сhoose a target table for the imported data
00:39 Options page Select range, configure headers
01:08 Data formats page
01:16 Mapping page
01:22 Using different modes
01:28 “Use a single transaction” - to roll back the data import
01:43 Set error processing rules
01:48 Let’s import data again
02:41 Exporting data from Data Editor (Export – SQL)
03:02 Select tables or views to be exported
03:12 Select a SQl statement type ( insert, update, delete, or merge)
03:22 Table columns page
03:31 Set a range of rows to be exported
03:45 The result of the export
03:55 The export of the selected columns
04:13 Select the MERGE statement type
04:21 select Export Selected Rows Only
👉🏽That's it! Try it yourself - just download a 30-day free trial of dbForge Studio
https://www.devart.com/dbforge/postgresql/studio/download.html
✅ Check a full list of other our import/export features:
https://www.devart.com/dbforge/postgresql/studio/data-export-import.html
👉 Take a look at dbForge Studio for PostgreSQL:
https://www.devart.com/dbforge/postgresql/studio/
►Subscribe to the Devart Youtube channel:
https://www.youtube.com/c/DevartSoftware
Thank you for watching!
Was this video helpful for you? Let us know what more information about dbForge Studio for PostgreSQL you’d see in the future videos.
#importpostgresql #exportpostgresql #psqldatabase #PostgreSQL
#dbForge #Devart #Devart
Closed Caption:
Welcome to dbForge Studio for PostgreSQL tutorials.
The tool offers a quick and convenient way
to import and export data.
First, let's consider importing data from
an .xls file.
Right-click the database in Database Explorer
and select Tools->Import Data on the shortcut
menu.
Then, select a file to import and specify
the file format.
On the Destination page, choose a target table.
You can either import data to the existing
table or create a new table for the imported
data.
On the Options page, select the range of cells
for import.
dbForge Studio for PostgreSQL allows transposing
data from rows to columns while importing.
Just click to select "Data In" rows or columns.
On this tab, you can also configure headers
for the imported data columns.
For example, you can select to use the first
row in a range as a header, specify a row
to be used as a header, or select not to use
headers at all.
On the Data formats page, you can configure
a data format for all columns or set a format
for each column separately.
On the Mapping page, you can modify the target
table structure, add new columns, change the
existing ones, etc.
The wizard allows using different modes when
processing data: appending, modifying, or
updating.
Click “Use a single transaction” if you
might need to roll back the data import afterwards,
since is better to perform it within one transaction
in this case.
On the next page, you can set error processing
rules.
Let’s import data again.
Select to add new data to the existing table,
enter its name in the Filter field, and select
the first table in the list.
The range of data for import can be selected
automatically or manually.
As you can see, there are no changes on the
Mapping page.
Select the import mode “Append/update”,
enable the Use a single transaction option,
and start importing.
Now, let’s take a look at the result.
dbForge Studio for PostgreSQL allows exporting
data directly from the Data Editor.
For this, click Export – SQL.
Alternatively, you may select the option from
the shortcut menu.
The settings can be saved.
On the Source page, you can select tables
or views to be exported to separate files
or to a single file.
On the Options page, select a SQL statement
type to be created: insert, update, delete,
or merge.
On the Table columns page, you can exclude
specific columns from export, set keys, and
change the column names.
On the Exported rows page, you can set a range
of rows to be exported: all rows, the selected
rows, or a specific range of rows.
And here is the result.
Now, let's consider the export of the selected
columns.
We have filtered data and selected rows to
export.
As you can see, the file name matches the
table name.
Select the MERGE statement type
and then, select Export Selected Rows Only.
Let’s take a look at the result.
Just download a 30-day free trial version
of dbForge Studio for PostgreSQL and find
out how easy and painless data import and
export can be.
Video Length: 04:53
Uploaded By: Devart
Published: 1/27/2022
View Count: 11,167