How to join two tables in two different projects in Google BigQuery?

For Example, Consider you have two projects having datasets. I want to perform a join of one table from the first project to table in the second project

Yes, you certainly can. You need to qualify the table name with the project name

#StandardSQL
select sum(a.is_male)
from
(select is_male, year from publicdata.samples.natality) a
inner join
(select year from moshap.my_years) b
on a.year = b.year

Atori

posted on 17 Aug 18

Enjoy great content like this and a lot more !

Signup for a free account to write a post / comment / upvote posts. Its simple and takes less than 5 seconds