Petunjuk dan persyaratan penyiapan lab
Lindungi akun dan progres Anda. Selalu gunakan jendela browser pribadi dan kredensial lab untuk menjalankan lab ini.

Visualize BigQuery Data with Looker Studio

Lab 15 menit universal_currency_alt 5 Kredit show_chart Menengah
info Lab ini mungkin menggabungkan alat AI untuk mendukung pembelajaran Anda.
Konten ini belum dioptimalkan untuk perangkat seluler.
Untuk pengalaman terbaik, kunjungi kami dengan komputer desktop menggunakan link yang dikirim melalui email.

GSP197

Google Cloud self-paced labs logo

Overview

Looker Studio helps you to unlock the power of your data through customized data visualizations and reports from a variety of data sources. You can share these visualizations and reports with specific stakeholders or publicly.

In this lab, you learn how to use Looker Studio to visualize data stored in BigQuery using historic information about internal flights in the United States from the US Bureau of Transport Statistics.

What you'll do

In this lab, you learn how to perform the following tasks:

  • Create BigQuery views.
  • Create a BigQuery data source in Looker Studio.
  • Create a Looker Studio report with a date range control.
  • Create multiple charts using BigQuery views.

Setup and requirements

Before you click the Start Lab button

Read these instructions. Labs are timed and you cannot pause them. The timer, which starts when you click Start Lab, shows how long Google Cloud resources are made available to you.

This hands-on lab lets you do the lab activities in a real cloud environment, not in a simulation or demo environment. It does so by giving you new, temporary credentials you use to sign in and access Google Cloud for the duration of the lab.

To complete this lab, you need:

  • Access to a standard internet browser (Chrome browser recommended).
Note: Use an Incognito (recommended) or private browser window to run this lab. This prevents conflicts between your personal account and the student account, which may cause extra charges incurred to your personal account.
  • Time to complete the lab—remember, once you start, you cannot pause a lab.
Note: Use only the student account for this lab. If you use a different Google Cloud account, you may incur charges to that account.

How to start your lab and sign in to the Google Cloud console

  1. Click the Start Lab button. If you need to pay for the lab, a dialog opens for you to select your payment method. On the left is the Lab Details pane with the following:

    • The Open Google Cloud console button
    • Time remaining
    • The temporary credentials that you must use for this lab
    • Other information, if needed, to step through this lab
  2. Click Open Google Cloud console (or right-click and select Open Link in Incognito Window if you are running the Chrome browser).

    The lab spins up resources, and then opens another tab that shows the Sign in page.

    Tip: Arrange the tabs in separate windows, side-by-side.

    Note: If you see the Choose an account dialog, click Use Another Account.
  3. If necessary, copy the Username below and paste it into the Sign in dialog.

    {{{user_0.username | "Username"}}}

    You can also find the Username in the Lab Details pane.

  4. Click Next.

  5. Copy the Password below and paste it into the Welcome dialog.

    {{{user_0.password | "Password"}}}

    You can also find the Password in the Lab Details pane.

  6. Click Next.

    Important: You must use the credentials the lab provides you. Do not use your Google Cloud account credentials. Note: Using your own Google Cloud account for this lab may incur extra charges.
  7. Click through the subsequent pages:

    • Accept the terms and conditions.
    • Do not add recovery options or two-factor authentication (because this is a temporary account).
    • Do not sign up for free trials.

After a few moments, the Google Cloud console opens in this tab.

Note: To access Google Cloud products and services, click the Navigation menu or type the service or product name in the Search field. Navigation menu icon and Search field

Task 1. Create views in BigQuery

This lab uses a BigQuery dataset that has been pre-loaded with two months of sample flight data for January and February 2015, which was obtained from the US Bureau of Transport Statistics. The flight data is in a table called flights_raw in the dsongcp dataset.

Open the BigQuery console

  1. In the Google Cloud Console, select Navigation menu > BigQuery.

The Welcome to BigQuery in the Cloud Console message box opens. This message box provides a link to the quickstart guide and the release notes.

  1. Click Done.

The BigQuery console opens.

You can close the Check out what's new in Studio screen.

Explore the source table in BigQuery

In this section, you explore the source table to see how the data is structured and the values contained, before creating new views from the source table.

  1. In the Explorer pane, expand your project ID (), then expand the dsongcp dataset, and click on the flights_raw table.

  2. In the new pane for the flights_raw table, if it isn't open by default, click the Schema tab to see the schema of the flights_raw table.

  3. Click Preview to view the columns and values in the flights_raw table.

Note: Outside of this lab environment, the preview functionality is no cost, whereas running a query on table, for example SELECT * FROM … LIMIT 10, incurs a querying cost.

Create BigQuery views

In this section, you create new views to easily see flights that are delayed by 10, 15, and 20 minutes respectively. In subsequent tasks, you use these views in Looker Studio to create visualizations.

  1. Switch to the Untitled query tab to prepare to create a new query.

  2. Copy and paste the following query, and click Run.

This query formats the original data values and column names in the source flights_raw table and saves the results to a new view named flights.

CREATE OR REPLACE VIEW dsongcp.flights -- Create view from dsongcp.flights_raw -- Source table is partitioned by date AS SELECT FlightDate AS FL_DATE, Reporting_Airline AS UNIQUE_CARRIER, OriginAirportSeqID AS ORIGIN_AIRPORT_SEQ_ID, Origin AS ORIGIN, DestAirportSeqID AS DEST_AIRPORT_SEQ_ID, Dest AS DEST, CRSDepTime AS CRS_DEP_TIME, DepTime AS DEP_TIME, CAST(DepDelay AS FLOAT64) AS DEP_DELAY, CAST(TaxiOut AS FLOAT64) AS TAXI_OUT, WheelsOff AS WHEELS_OFF, WheelsOn AS WHEELS_ON, CAST(TaxiIn AS FLOAT64) AS TAXI_IN, CRSArrTime AS CRS_ARR_TIME, ArrTime AS ARR_TIME, CAST(ArrDelay AS FLOAT64) AS ARR_DELAY, IF(Cancelled = '1.00', True, False) AS CANCELLED, IF(Diverted = '1.00', True, False) AS DIVERTED, DISTANCE FROM dsongcp.flights_raw;
  1. Click + (SQL query) to create a new query.

  2. Copy and paste the following queries, and click Run.

These queries select data from the new view named flights based on departure delay times and saves the results to new views.

-- Create view for delays greater than or equal to 10 mins CREATE OR REPLACE VIEW dsongcp.delayed_10 AS SELECT * FROM dsongcp.flights WHERE dep_delay >= 10; -- Create view for delays greater than or equal to 15 mins CREATE OR REPLACE VIEW dsongcp.delayed_15 AS SELECT * FROM dsongcp.flights WHERE dep_delay >= 15; -- Create view for delays greater than or equal to 20 mins CREATE OR REPLACE VIEW dsongcp.delayed_20 AS SELECT * FROM dsongcp.flights WHERE dep_delay >= 20; Create views in BigQuery

Task 2. Create a BigQuery data source in Looker Studio

  1. In a new browser tab, open Looker Studio.

  2. If needed, click Use it for free, and click Not now on the Get Looker Studio Pro message.

  3. Click Data sources in the top menu.

  4. On the top left, click + Create > Data source.

  5. Select a Country and provide a Company name.

  6. Agree to the Terms of service and click Continue.

  7. Select No for all email preferences, then click Continue.

  8. In the list of Google Connectors, click the BigQuery tile.

  9. Click Authorize to enable access from Looker Studio to your Cloud sources.

  10. If needed, be sure your lab account () is selected.

  11. Click to select My projects > > dsongcp > flights.

  12. Click the blue Connect button on the upper right of the screen.

Create a BigQuery data source in Looker Studio

Task 3. Create a scatter chart using Looker Studio

  1. Click Create report at the top right of the page.

  2. Click Add to report to confirm that you want to add the flights table as a data source.

  3. Click Freeform layout.

  4. Replace Untitled Report in the top left with your name for this report such as Flight Delays.

  5. Since you'll create your own charts, click to select it, then delete the automatically created chart.

  6. Click Add a chart > Scatter chart, then draw a rectangle on the report canvas to hold the chart.

Add a chart drop-down menu

In the right panel, the Data tab lists the data properties.

  1. In the Data tab in the right panel, on the Setup tab, click the field for the settings below and change to the following:
Field Value

Dimension

UNIQUE_CARRIER

Metric X

DEP_DELAY

Metric Y

ARR_DELAY

  1. Hover your mouse over the data type icon (SUM) of the Metric X property.

The Metric X property

  1. Click the pencil icon to edit the aggregation type of Metric X.

The Metric X Edit icon

  1. Change the aggregation type to Average.

  2. Click outside the aggregation type box to return to the property pane.

  3. Do the same for Metric Y to change the aggregation type from SUM to Average.

  4. Click the Style tab.

  5. In the Style menu, click the Trendline drop-down, and select Linear.

  6. In the ribbon above the report, click Add a control > Date range control.

The expanded Add a Control drop-down menu with the Date range control option highlighted
  1. Draw a rectangle the size of a label below the chart to add the Date range control.

Try it out!

  1. Set a date range between January 1, 2015 and February 28, 2015 by either:
  • Clicking Auto data range in the Date range control Properties panel on the right.
  • Clicking the Date range control rectangle you added under the scatter chart.
  1. Click the View button on the upper right to change to the interactive report view to test this control.
Note: You see data only if the range includes dates between Jan 1st, 2015 and Feb 28th, 2015 because the dataset is limited to those dates in this lab.

Scatter plot

Task 4. Add additional chart types to your report

Add a pie chart

  1. Click Edit on the upper right to add more chart items.

  2. Click Add a chart > Pie chart, then draw a rectangle on the report canvas to hold the pie chart.

  3. With the pie chart selected, click Add a field on the bottom right of the Data tab in the right panel.

Note: If you do not see the Add a field option, refresh your browser tab.
  1. Click Add calculated field to view the field property summary.

  2. Click All fields to view the field property summary.

  3. Click the context menu icon to the right of the ARR_DELAY field (three dots) and select Duplicate.

The context menu icon alongside the ARR_DELAY field

  1. Click Add a field on the top right of the section.

  2. Click Add calculated field and name the field is_late.

  3. In the Formula text box enter the following formula:

CASE WHEN ( Copy of ARR_DELAY <15) THEN "ON TIME" ELSE "LATE" END

The field name must register correctly. If you do not see the syntax highlighting as shown below, double-check the formula or use the Available Fields selector on the right to select the Copy of ARR_DELAY field.

The Formula editor with Copy of ARR_DELAY highlighted

  1. Click Save and then click Done.

  2. In the Data tab in the right panel, on the Setup tab, change the Dimension for the Pie chart to the new is_late calculated field.

Note: Your chart will likely show an error at this point. This will be fixed by the next few steps.
  1. Change the Metric to the new is_late field.

  2. Hover over the CTD icon next the is_late metric.

  3. Click it and change the aggregation to Count.

The pie chart now displays the percentage of on time and late flights.

Pie chart

Add a bar chart

  1. Click Add a chart > Vertical bar chart, and then draw a rectangle on the report canvas to hold the bar chart.

  2. In the Data tab in the right panel, on the Setup tab, click the field for the settings below and change to the following:

Field Value

Dimension

UNIQUE_CARRIER

Metric 1 (Default)

DEP_DELAY

Metric 2 (click Add metric)

ARR_DELAY

Sort

UNIQUE_CARRIER

Sort Order

Ascending

  1. In the Style tab, under Axes, change from Single to Double.

  2. Scroll to Left Y-Axis, and set the Axis Min value to 0.

  3. Scroll to Right Y-Axis, and set the Axis Min value to 0.

Bar chart

Task 5. Create additional dashboard items for different departure delay thresholds

In a previous task, you created 3 views for delayed times of 10, 15, and 20 minutes. Now you create charts to display the delay thresholds for these tables.

Add an additional data source for the delayed_10 view

  1. Click on the pie chart to select it, and make a copy of it by clicking Edit > Copy in the Looker Studio menu bar.
  2. In the Looker Studio menu bar, select Edit > Paste to paste the pie chart and position it in an area of the canvas not occupied by another chart.

You now have a set of two pie charts. The report canvas should now look similar to this:

The Report canvas containing a dot chart, two pie charts, and a bar chart.

  1. Select the second pie chart, and on the Setup tab, click flights in the Data Source in the property list.

  2. Click Add data at the bottom of the menu. The Data source drop-down list with Add data highlighted

  3. Click BigQuery in the Google Connectors section of the selection pane.

  4. Select My projects > > dsongcp.

  5. Click the delayed_10 table to select it, and then click the Add button on the bottom right of the screen.

Note: This is technically a table view, not a table, but it is listed as a table in the interface.
  1. Click Add to report to confirm.

Recreate the copy of the Arr_Delay field and the is_late calculated field

  1. Click flights in the Data source section of the Setup tab and select delayed_10 from the Added data sources list.
The Data source drop-down list with delayed_10 highlighted
Note: You may need to refresh the page to see delayed_10 listed in the Data pane once you've made this change.
  1. Scroll down and click Add a field on the bottom right of the screen.

  2. Click Add calculated field to view the field property summary.

  3. If you cannot see the full list of fields with their data type and Aggregation type displayed, click All fields to go to the field property summary.

  4. Click the context menu icon to the right of the ARR_DELAY field and select Duplicate.

The Context menu icon alongside the ARR_DELAY field

  1. Click Add a field (menu bar above the field names).

  2. Click Add calculated field and name the field is_late.

  3. Enter the following formula in the Formula text box:

CASE WHEN ( Copy of ARR_DELAY <15) THEN "ON TIME" ELSE "LATE" END

The field name must register correctly. If you do not see the syntax highlighting as shown below then double check the formula or use the Available Fields selector on the right to select the Copy of ARR_DELAY field.

The Formula editor with 'Copy of ARR_DELAY' highlighted

  1. Click Save and click Done.

  2. In the Data tab in the right panel, on the Setup tab, change the Dimension for the Pie chart to the new is_late calculated field.

The second pie chart now retains the is_late calculated field and displays the percentage of on time and late flights for the delayed_10 view.

The Report canvas displaying the second pie chart updated

Task 6. Create the remaining dashboard views (optional)

Optionally, repeat the last two sections to add connections to the delayed_15 and delayed_20 views, and create additional pie charts.

Congratulations!

You used Looker Studio to visualize data stored in BigQuery tables and views.

Next steps / Learn more

Google Cloud training and certification

...helps you make the most of Google Cloud technologies. Our classes include technical skills and best practices to help you get up to speed quickly and continue your learning journey. We offer fundamental to advanced level training, with on-demand, live, and virtual options to suit your busy schedule. Certifications help you validate and prove your skill and expertise in Google Cloud technologies.

Manual Last Updated March 25, 2026

Lab Last Tested March 25, 2026

Copyright 2026 Google LLC. All rights reserved. Google and the Google logo are trademarks of Google LLC. All other company and product names may be trademarks of the respective companies with which they are associated.

Sebelum memulai

  1. Lab membuat project dan resource Google Cloud untuk jangka waktu tertentu
  2. Lab memiliki batas waktu dan tidak memiliki fitur jeda. Jika lab diakhiri, Anda harus memulainya lagi dari awal.
  3. Di kiri atas layar, klik Start lab untuk memulai

Gunakan penjelajahan rahasia

  1. Salin Nama Pengguna dan Sandi yang diberikan untuk lab tersebut
  2. Klik Open console dalam mode pribadi

Login ke Konsol

  1. Login menggunakan kredensial lab Anda. Menggunakan kredensial lain mungkin menyebabkan error atau dikenai biaya.
  2. Setujui persyaratan, dan lewati halaman resource pemulihan
  3. Jangan klik End lab kecuali jika Anda sudah menyelesaikan lab atau ingin mengulanginya, karena tindakan ini akan menghapus pekerjaan Anda dan menghapus project

Konten ini tidak tersedia untuk saat ini

Kami akan memberi tahu Anda melalui email saat konten tersedia

Bagus!

Kami akan menghubungi Anda melalui email saat konten tersedia

Satu lab dalam satu waktu

Konfirmasi untuk mengakhiri semua lab yang ada dan memulai lab ini

Gunakan penjelajahan rahasia untuk menjalankan lab

Menggunakan jendela Samaran atau browser pribadi adalah cara terbaik untuk menjalankan lab ini. Langkah ini akan mencegah konflik antara akun pribadi Anda dan akun Siswa, yang dapat menyebabkan tagihan ekstra pada akun pribadi Anda.