mediumMultiple Choice
Generative AI Leader Practice Question: A data analyst wants to build a regression model…
A data analyst wants to build a regression model in BigQuery to predict sales from historical data without writing any Python code. Which BigQuery ML statement should they use to define the model?
⚠ Common exam trap
Test-takers frequently confuse BigQuery ML's declarative CREATE MODEL DDL with procedural ML APIs like ML.TRAIN or Python-style fit/predict calls, causing candidates to pick a plausible-sounding but nonexistent statement.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
CREATE MODEL my_model OPTIONS(model_type='linear_reg') AS SELECT ...
BigQuery ML uses the standard SQL DDL statement CREATE MODEL with an OPTIONS clause specifying model_type (e.g., 'linear_reg') and a training query supplied via AS SELECT. This lets analysts train and deploy ML models entirely in SQL without exporting data or writing Python. The linear_reg model type trains a linear regression on the selected features and label column.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
CREATE MODEL my_model OPTIONS(model_type='linear_reg') AS SELECT ...
Why this is correct
`CREATE MODEL ... OPTIONS(model_type='linear_reg')` trains a linear regression directly in BigQuery using SQL, satisfying the no-Python constraint. BigQuery ML supports regression natively, so the analyst defines and fits the model without exporting data or provisioning external tooling.
- ✗
INSERT INTO model my_model VALUES ...
Why it's wrong here
INSERT INTO adds rows to an existing table; it cannot define a model. It suits loading data into BigQuery tables. Defining a regression model without Python requires CREATE MODEL with the model type and training query, which INSERT cannot express.
- ✗
CREATE ML my_model AS (SELECT ...)
Why it's wrong here
CREATE ML is not valid BigQuery ML syntax; the correct keyword sequence is CREATE MODEL. This near-miss tempts because it gestures at DDL model creation. Defining a regression model without Python requires CREATE MODEL ... AS (SELECT ...), which this malformed statement fails to be.
- ✗
SELECT ML.TRAIN('linear_reg', ...)
Why it's wrong here
ML.TRAIN is not a BigQuery ML model-creation statement; models are defined with CREATE MODEL. A SELECT calling ML.TRAIN would suit nothing here. The analyst needs CREATE MODEL with linear_reg and a training SELECT, which this syntax does not provide.
Go deeper
Related to this question
About these practice questions
One of 1,008 original Generative AI Leader practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written and reviewed by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
Last reviewed September 2026 · checked against the official Google Cloud exam blueprint
This Generative AI Leader practice question is part of Courseiva's free Google Cloud certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the Generative AI Leader exam.