gcloud alpha sql instances import Stay organized with collections Save and categorize content based on your preferences.
- NAME
- gcloud alpha sql instances import - imports data into a Cloud SQL instance from Google Cloud Storage
- SYNOPSIS
gcloud alpha sql instances importINSTANCEURI[--async][--database=DATABASE,-dDATABASE][GCLOUD_WIDE_FLAG …]
- DESCRIPTION
(ALPHA)(DEPRECATED)Imports data into a Cloud SQLinstance from Google Cloud Storage.This command is deprecated and will be removed in version 205.0.0. Use
gcloud sql import sqlinstead.Note: authorization is required. For more information on importing data intoGoogle Cloud SQL seehttps://cloud.google.com/sql/docs/import-export/importing.
Cloud SQL supports importing CSV files and SQL dump files from both MySQL andPostgreSQL. For more information on how to create these export formats, seehttps://cloud.google.com/sql/docs/mysql/import-export/creating-sqldump-csv
- POSITIONAL ARGUMENTS
INSTANCE- Cloud SQL instance ID.
URI- Path to the MySQL dump file in Google Cloud Storage from which the import ismade. The URI is in the form gs://bucketName/fileName. Compressed gzip files(.gz) are also supported.
- FLAGS
--async- Return immediately, without waiting for the operation in progress to complete.
--database=DATABASE,-dDATABASE- Database to which the import is made. The database needs to be created beforeimporting. If not set, it is assumed that the database is specified in the fileto be imported. If your SQL dump file includes a database statement, it willoverride the database set in this flag.
- GCLOUD WIDE FLAGS
- These flags are available to all commands:
--access-token-file,--account,--billing-project,--configuration,--flags-file,--flatten,--format,--help,--impersonate-service-account,--log-http,--project,--quiet,--trace-token,--user-output-enabled,--verbosity.Run
$gcloud helpfor details. - NOTES
- This command is currently in alpha and might change without notice. If thiscommand fails with API permission errors despite specifying the correct project,you might be trying to access an API with an invitation-only early accessallowlist. These variants are also available:
gcloudsqlinstancesimportgcloudbetasqlinstancesimport
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-05-07 UTC.