Best Practices for Importing and Exporting Data

This page provides best practices for importing and exporting data with Cloud SQL. For step-by-step instructions for importing data into Cloud SQL, see Importing Data. For step-by-step instructions for export your data, whether it is in Cloud SQL or an instance you manage, see Exporting Data.

Best practices for importing and exporting

The following are best practices you should consider when importing and exporting data:

Use the correct flags when you create a SQL dump file

If you do not use the correct procedure when you export your data to a SQL dump file, your import might not be successful. For information about creating a SQL dump file for import into Cloud SQL, see Exporting data.

Compress data to reduce cost

Cloud SQL supports importing and exporting both compressed and uncompressed files. Compression can save significant storage space on Cloud Storage and reduce your storage costs, especially when you are exporting large instances. When you export a SQL dump or CSV file, use a .gz file extension to compress the data. When you import a file with an extension of .gz, it is decompressed automatically.

What's next

Was this page helpful? Let us know how we did:

Send feedback about...

Cloud SQL for PostgreSQL