BigQuery Machine Learning (BQML) is an effective tool developed by Google Cloud to construct and use machine learning models using SQL. The service helps you to effortlessly use ML predictions without the need to move your data. Here's a brief guide on how to use BQML to make predictions.

Step 1: Import Your Data #

First, you need to import your data into BigQuery. If it's not already there, you'll have to create a dataset and load your data.

CREATE OR REPLACE TABLE `project_id.dataset.table`
OPTIONS(
description="My imported data"
) AS
SELECT
*
FROM
`project_id.source_dataset.source_table`;

Step 2: Create a Machine Learning Model #

Next, we'll create a machine learning model using the data we imported. BigQuery offers a range of models (linear regression, logistic regression, k-means clustering, etc.). In this example, we'll use a linear regression model.

CREATE OR REPLACE MODEL `project_id.dataset.model`
OPTIONS(model_type='linear_reg') AS
SELECT
feature_1,
feature_2,
target_variable
FROM
`project_id.dataset.table`;

Step 3: Evaluate the Model #

After creating the model, we need to evaluate its performance to ensure it's effective for our needs. BigQuery provides an EVALUATE function for this.

SELECT
*
FROM
ML.EVALUATE(MODEL `project_id.dataset.model`, (
SELECT
feature_1,
feature_2,
target_variable
FROM
`project_id.dataset.table_test`));

Step 4: Use the Model to Make Predictions #

Once the model is trained and evaluated, we can use it to make predictions on new data.

SELECT
feature_1,
feature_2,
target_variable,
ML.PREDICT(MODEL `project_id.dataset.model`, (
SELECT
feature_1,
feature_2
FROM
`project_id.dataset.table_unseen`)) AS prediction
FROM
`project_id.dataset.table_unseen`;

Remember, using BQML is as simple as writing some SQL statements. It makes the application of machine learning to your data straightforward, without the need for complex code or to move your data around.