The EXPORT MODEL statement

Overview

To export an existing model from BigQuery ML to Cloud Storage, use the EXPORT MODEL statement.

For more information about supported model types, formats, and limitations, see Export models.

For information about supported model types of each SQL statement and function, and all supported SQL statements and functions for each model type, read End-to-end user journey for each model.

Syntax

The following is the syntax of EXPORT MODEL for a regular model that is not generated from BigQuery ML hyperparameter tuning.

EXPORT MODEL MODEL_NAME [OPTIONS(URI = STRING_VALUE)]

For a model that is generated from BigQuery ML hyperparameter tuning, EXPORT MODEL can also export an individual trial to a destination URI. For example:

EXPORT MODEL MODEL_NAME [OPTIONS(URI = STRING_VALUE [, TRIAL_ID = INT_VALUE])]