Search code examples
postgresqlgoogle-cloud-platformexportexport-to-csvgoogle-cloud-sql

Cloud SQL for PostgreSQL database export in GCP


I have a PostgreSQL database in Cloud SQL, and I want to export some data from it using the UI.

Just after hitting the Export button you are shown the following warning:

The SQL export process may take a long time (possibly an hour or more for large instances). You will not be able to perform operations on your instance for the entire duration of the export. Once begun, this process cannot be canceled.

What does "perform operations" mean?

Will my application still be able to query (read and write) the database while the export is ongoing?


Solution

  • What does "perform operations" mean?

    Perform operations in this context would mean changing instance configurations, so long your instance has excess capacity to process your export your app can continue to use the DB.

    Will my application still be able to query (read and write) the database while the export is ongoing?

    Yes, although there might be a performance impact on the app, depending on size of the DB instance and the size of the export.

    Have a look at the best practices guide (if you haven't already), while exporting from PostgresDB.

    If you are worried about the performance impact on the app / end-users, you could create a read replica of your existing DB and export the data from the replica.