Help Center> GaussDB(DWS)> Developer Guide> Guide: JDBC- or ODBC-Based Development> JDBC-Based Development> Example: Importing and Exporting Data Through Local Files
Updated on 2023-10-31 GMT+08:00

Example: Importing and Exporting Data Through Local Files

When the JAVA language is used for secondary development based on GaussDB(DWS), you can use the CopyManager interface to export data from the database to a local file or import a local file to the database by streaming. The file can be in CSV or TEXT format.

The sample program is as follows. Load the GaussDB(DWS) JDBC driver before running it.