
Before you begin
- Labs create a Google Cloud project and resources for a fixed time
- Labs have a time limit and no pause feature. If you end the lab, you'll have to restart from the beginning.
- On the top left of your screen, click Start lab to begin
Created an Authorized Table
/ 40
Create an authorized view in the Data Publishing project
/ 40
Access the authorized view as a Data Twin
/ 20
A common scenario is where a Google Cloud Data Sharing Partner has proprietary datasets that customers can use for their analytics use cases. Customers need to subscribe to this data, query it within their own platform, then augment it with their own datasets and use their visualization tools for their customer facing dashboards. This enables Data Sharing Partners to simplify and accelerate how they build and deliver value from data-driven solutions.
Through integration with Google Cloud IAM, you can set permissions on BigQuery objects to enable access by users inside or outside of organizations. In this lab, you will learn how Data Sharing Partners create Data Twins for customers either on Google Cloud or a different cloud service provider. For the purposes of this lab, the customer is on Google Cloud in a different project.
In this lab, you will wear two hats and be provided with three Google Cloud projects. In the first project, you are taking on the role of a Data Sharing Partner sharing a dataset generated by the partner's hosted solution using a Data Publishing project. In the second project, you will assume the role of a Data Sharing Partner who will share the source dataset in partner project as an authorized view in the Data Publishing project. In the third project, you will assume the role of a customer who will access the authorized view into their project as a Data Twin and join the data with their solution dataset to create enriched datasets.
In this lab, you will:
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:
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:
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.
If necessary, copy the Username below and paste it into the Sign in dialog.
You can also find the Username in the Lab Details pane.
Click Next.
Copy the Password below and paste it into the Welcome dialog.
You can also find the Password in the Lab Details pane.
Click Next.
Click through the subsequent pages:
After a few moments, the Google Cloud console opens in this tab.
In the first project, you will take on the role of a Data Sharing Partner creating and sharing a dataset using an authorized table.
From the lab pane. open the Data Sharing Partner Project Console and log in with the associated credentials.
From the Navigation Menu, go to BigQuery > BigQuery Studio.
Run the following query to create a source dataset by selecting the top 10 cities of each state sorted by land area:
Select the Set a destination table for query results option.
For the Dataset select
.
For Table ID type authorized_table
.
Leave the rest of the fields as default and click Save.
Click Run to run the query again to write the results to the table you specified.
Verify the authorized_table
has been created.
From the BigQuery Explorer pane, open the demo_dataset and click + Sharing > Authorize datasets.
Add the authorized view that needs to be authorized to share:
.
Click Add Authorization.
Click Close.
Under your project, inside of demo_dataset, open authorized_table
.
Click Share.
Click on Add Principal and add the Data Publisher and Customer users:
Select the BigQuery Data Viewer role.
Click Check my progress to verify your performed task.
In the second project, you will assume the role of a Data Sharing Partner who will share the source dataset in partner project as an authorized view in the Data Publishing project.
Close the Data Sharing Partner Project Console and from the lab pane open the Data Publisher Project Console. Log in with the associated credentials.
From the Navigation Menu, go to BigQuery > BigQuery Studio.
Run the following query to select cities in New York state from the authorized view:
On the query toolbar, select Save > Save View.
Click in the Dataset field and select data_publisher_dataset
.
In the Table field, type authorized_view
.
Click Save. You should now be able to see the dataset and table, as well as query it.
From the BigQuery Explorer pane, open the data_publisher_dataset and click + Sharing > Authorize Views.
Add the authorized view that needs to be authorized to share:
.
Click Add Authorization.
Click Close.
Under your project, inside of data_publisher_dataset, open authorized_view
.
Click Share.
Click on Add Principal and add the Customer user:
Select the BigQuery Data Viewer role.
Click Check my progress to verify your performed task.
In the third project, the student will assume the role of a customer who will access the authorized view into their project as a Data Twin and join the data with their solution dataset to create enriched datasets.
Close the Data Publisher Console and from the lab pane open the Customer (Data Twin) Project Console. Log in with the associated credentials.
From the Navigation Menu, go to BigQuery > BigQuery Studio.
Execute the following query to access data from the Data Sharing Partner Data publishing project and join the Customer’s data and partner's view to create new insights.
Your results should resemble the following:
On the query toolbar, select Save > Save View.
Click in the Dataset field and select customer_dataset
.
In the Table field, type customer_table
.
Click Save. You should now be able to see the dataset and table, as well as query it.
Click Check my progress to verify your performed task.
To confirm the functionality of the Data Twin, you will insert a new row in the Data Sharing Partner Project and test the functionality inside of the customer project.
Close the Customer (Data Twin) Project Console and from the lab pane open the Data Sharing Partner Project Console. Log in with the associated credentials.
From the Navigation Menu, go to BigQuery > BigQuery Studio.
Run the following query to insert a new row in the Data Sharing Partner dataset:
You should see the following output
Close the Data Sharing Partner Project Console and from the lab pane open the Customer (Data Twin) Project Console. Log in with the associated credentials.
Finally, query the view in Customer (Data Twin) project to confirm the newly added row is visible.
You results should resemble the following:
In this lab, you created an authorized view for an Data Sharing Partner dataset to share with a user in a Data Publishing project. You then logged into the Data Publishing project and shared the authorized view with a customer user in a Data Twin project. Lastly, you logged into the Customer/Data Twin project and joined the data with customer specific data to create an enriched dataset.
...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 21, 2025
Lab Last Tested March 21, 2025
Copyright 2025 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.
This content is not currently available
We will notify you via email when it becomes available
Great!
We will contact you via email if it becomes available
One lab at a time
Confirm to end all existing labs and start this one