SlideShare a Scribd company logo
Google BigQuery
- Command line and Tips -
2016/06/08
Mulodo Vietnam Co., Ltd.
What’s BigQuery
Official site : https://cloud.google.com/bigquery/docs/
BigQuery is Google's fully managed, petabyte scale, low
cost analytics data warehouse.
BigQuery is NoOps—there is no infrastructure to manage
and you don't need a database administrator—so you can
focus on analyzing data to find meaningful insights, use
familiar SQL, and take advantage of our pay-as-you-go
model.
→ DWH: SQL like (easy to use), Petabyte scale(for Huge data)
Previous study
“BigQuery - The First Step -“ (2016/05/26)
• Just try to start for Google Big Query
• Using query on the Google Cloud Platform console.
• Create your own Dataset and Table
• Using query for your table GPC console.
http://www.meetup.com/Open-Study-Group-Saigon/events/231233151/
http://www.slideshare.net/nemo-mulodo/big-query-the-first-step-mosg
c.f. “Big Data - Overview - “
http://www.slide http://www.meetup.com/Open-Study-Group-Saigon/events/229243903/
share.net/nemo-mulodo/big-data-overview-mosg
Command line tools and Tips
1. Preparation (install SDK and settings)
2. Try command line tools
create datasets, tables and insert data.
3. Tips for business use.
How to charge?
Tips to reduce cost.
1. Preparation steps
Preparation steps
1. Create “Google Cloud Platform(GCP)” account, and
BigQuery.
See) previous paper.
2. Install GCP SKD to your PC. (Using Ubuntu on Vagrant)
1. Installation
2. Activate your account
3. Set accounts for GCP SDK.
2. Install GCP SKD
1. Installation
Install SKD to your PC. (1)
nemo@ubuntu-14:~$ curl https://sdk.cloud.google.com | bash
:
Installation directory (this will create a google-cloud-sdk subdirectory)
(/home/nemo): <-- Just type Enter (or you want)
:
Do you want to help improve the Google Cloud SDK (Y/n)? y
:
! BigQuery Command Line Tool ! 2.0.24 ! < 1 MiB !
! BigQuery Command Line Tool (Platform Specific)! 2.0.24 ! < 1 MiB !
:
Modify profile to update your $PATH and enable shell command
completion? (Y/n)? y (or you want)
:
For more information on how to get started, please visit:
https://cloud.google.com/sdk/#Getting_Started
nemo@ubuntu-14:~$ . ~/.bashrc <-- reload your bash environment
nemo@ubuntu-14:~$
Install SKD to your PC. (2)
// check the commands
nemo@ubuntu-14:~$ which bq
/home/nemo/google-cloud-sdk/bin/bq
nemo@ubuntu-14:~$ which gcloud
/Users/nemo/google-cloud-sdk/bin/gcloud
2. Install GCP SKD
2. Activate your account
Activate your GPC account (1)
1. Preparation (create account)
2. Go to Google Cloud platform (has no account)
3. “Try IT Free”
https://cloud.google.com
nemo@ubuntu-14:~$ gcloud init
Welcome! This command will take you through the configuration of gcloud.
Your current configuration has been set to: [default]
To continue, you must log in. Would you like to log in (Y/n)?
Go to the following link in your browser:
https://accounts.google.com/o/oauth2/auth?redirect_uri=ur&xxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
access_type=offline
Enter verification code: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
You are now logged in as: [xxxx@example.com]
This account has no projects. Please create one in developers console (https://
console.developers.google.com/project) before running this command.
nemo@ubuntu-14:~$
nemo@ubuntu-14:~$ gcloud init
Welcome! This command will take you through the configuration of gcloud.
Your current configuration has been set to: [default]
To continue, you must log in. Would you like to log in (Y/n)?
Go to the following link in your browser:
https://accounts.google.com/o/oauth2/auth?redirect_uri=ur&xxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
access_type=offline
Enter verification code: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
You are now logged in as: [xxxx@example.com]
This account has no projects. Please create one in developers console (https://
console.developers.google.com/project) before running this command.
nemo@ubuntu-14:~$
Activate your GPC account (2)
https://accounts.google.com/o/oauth2/auth?redirect_uri=ur&xxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
access_type=offline
Launch
Browser
Select accounts
(if you already login with
multiple accounts)
Activate your GPC account (3)
https://accounts.google.com/o/oauth2/auth?redirect_uri=ur&xxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
access_type=offline
Accept
permission
Activate your GPC account (4)
https://accounts.google.com/o/oauth2/auth?redirect_uri=ur&xxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
access_type=offline
get
verification code
Activate your GPC account (5)
https://accounts.google.com/o/oauth2/auth?redirect_uri=ur&xxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
access_type=offline
Enter verification code: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
You are now logged in as: [xxxx@example.com]
set the code
Activate your GPC account (6)
https://accounts.google.com/o/oauth2/auth?redirect_uri=ur&xxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
access_type=offline
Enter verification code: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
You are now logged in as: [xxxx@example.com]
check the accounts
Activate your GPC account (7)
Activate your GPC account (8)
// set Project ID
nemo@ubuntu-14:~$ gcloud config set project {{PROJECT_ID}}
nemo@ubuntu-14:~$
// check the accounts
nemo@ubuntu-14:~$ gcloud auth list
- xxx@example.com (active)
To set the active account, run:
$ gcloud config set account ``ACCOUNT''
nemo@ubuntu-14:~$
What a pain!
AWS is much easiler...
2. Try command line tools
Try Public data (1)
nemonemo@ubuntu-14:~$ bq show publicdata:samples.shakespeare
Table publicdata:samples.shakespeare
Last modified Schema Total
Rows Total Bytes Expiration
----------------- ------------------------------------
------------ ------------- ------------
26 Aug 21:43:49 |- word: string (required) 164656
6432064
|- word_count: integer (required)
|- corpus: string (required)
|- corpus_date: integer (required)
	publicdata		:		samples		.	shakespeare	
{PROJECT_ID}	:	{DATASET}	.			{TABLE}
Try Public data (2)
nemo@ubuntu-14:~$ bq query "SELECT word, COUNT(word) as count FROM
publicdata:samples.shakespeare WHERE word CONTAINS 'raisin' GROUP BY word"
Waiting on bqjob_r5e78fd2c80d5923c_000001554d1c4acc_1 ... (0s) Current
status: DONE
+---------------+-------+
| word | count |
+---------------+-------+
| raising | 5 |
| dispraising | 2 |
| Praising | 4 |
| praising | 7 |
| dispraisingly | 1 |
| raisins | 1 |
+---------------+-------+
nemo@ubuntu-14:~$
Create Dataset (1)
nemo@ubuntu-14:~$ bq ls
<--- no dataset
nemo@ubuntu-14:~$ bq mk saigon_engineers
Dataset 'open-study-group-saigon:saigon_engineers' successfully created.
nemo@ubuntu-14:~$ bq ls
datasetId
------------------ <-- created!!
saigon_engineers
nemo@ubuntu-14:~$
Create Dataset (2)
nemo@ubuntu-14:~$ bq ls
<--- no dataset
nemo@ubuntu-14:~$ bq mk saigon_engineers
Dataset 'open-study-group-saigon:saigon_engineers' successfully created.
nemo@ubuntu-14:~$ bq ls
datasetId
------------------ <-- created!!
saigon_engineers
nemo@ubuntu-14:~$
Added!! -->
Create table and import data (1)
name type
ID INTEGER
name STRING
engineer_type INTEGER
ID name type
1 nemo 1
2 miki 1
Schema
Data
Create table and import data (2)
Schema (schema.json)
[
{
"name":"id",
"type":"INTEGER"
},
{
"name":"name",
"type":"STRING"
},
{
"name":"engineer_type",
"type":"INTEGER"
}
]
Create table and import data (3)
Data (data.json)
{"id":1,"name":"nemo","engineer_type":1}
{"id":2,"name":"miki","engineer_type":1}
Create table and import data (4)
nemo@ubuntu-14:~$ bq load --source_format=NEWLINE_DELIMITED_JSON
saigon_engineers.engineer_list data.json schema.json
Upload complete.
Waiting on bqjob_r23b898932d75d49a_000001554e5cae2f_1 ... (1s)
Current status: DONE
nemo@ubuntu-14:~$
bk load {PROJECT_ID}:{DATASET}.{TABLE} {data} {schema}
Create table and import data
https://cloud.google.com/bigquery/loading-data
Create table and import data (5)
nemo@ubuntu-14:~$ bq load --source_format=NEWLINE_DELIMITED_JSON
saigon_engineers.engineer_list data.json 
id:integer,
name:string,
engineer_type:integer
Upload complete.
Waiting on bqjob_r33b7802ea96b2c5d_000001554e4d21d5_1 ... (2s)
Current status: DONE
nemo@ubuntu-14:~$
Create table and import data : Another way
Create table and import data (6)
nemo@ubuntu-14:~$ bq mk open-study-group-
saigon:saigon_engineers.engineer_list schema.json
nemo@ubuntu-14:~$
Create table
bk mk {PROJECT_ID}:{DATASET}.{TABLE} {schema}
Create table and import data (7)
nemo@ubuntu-14:~$ bq load --source_format=NEWLINE_DELIMITED_JSON
saigon_engineers.engineer_list data.json
Upload complete.
Waiting on bqjob_r13717485c2c472e3_000001554e5b3ca3_1 ... (2s)
Current status: DONE
nemo@ubuntu-14:~$
Import data to database
bk load {PROJECT_ID}:{DATASET}.{TABLE} {data}
Query (1)
nemo@ubuntu-14:~$ bq show saigon_engineers.engineer_list
Last modified Schema Total Rows
Total Bytes Expiration
----------------- --------------------------- ------------
------------- ------------
14 Jun 10:02:35 |- id: integer 2 44
|- name: string
|- engineer_type: integer
nemo@ubuntu-14:~$
Query (2)
nemo@ubuntu-14:~$ bq query "SELECT name FROM
saigon_engineers.engineer_list"
Waiting on bqjob_r12185d1aa88d92c8_0000015552d709d2_1 ... (0s)
Current status: DONE
+------+
| name |
+------+
| nemo |
| miki |
+------+
nemo@ubuntu-14:~$
Query (3)
nemo@ubuntu-14:~$ bq query --dry_run "SELECT name FROM
saigon_engineers.engineer_list"
Query successfully validated. Assuming the tables are not
modified, running this query will process 12 bytes of data.
nemo@ubuntu-14:~$
bk query --dry_run “QUERY”
- get size of using memory before execution.
Hmm.
(finished??)
A bit more
3. Tips for business use
Pricing
Storage															$0.02	per	GB,	per	month		
Long	Term	Storage					$0.01	per	GB,	per	month	
Streaming	Inserts					$0.01	per	200	MB	
Queries															$5	per	TB	(First	1	TB	per	month	is	free)	
																						subject	to	query	pricing	details.	
Loading	data										Free	
Copying	data										Free	
Exporting	data									Free	
Metadata	operations			Free	
																						List,	get,	patch,	update	and	delete	calls.
It seems very cheap !!?
Pricing
Storage															$0.02	per	GB,	per	month		
Long	Term	Storage					$0.01	per	GB,	per	month	
Streaming	Inserts					$0.01	per	200	MB	
Queries															$5	per	TB	(First	1	TB	per	month	is	free)	
																						subject	to	query	pricing	details.	
Loading	data										Free	
Copying	data										Free	
Exporting	data									Free	
Metadata	operations			Free	
																						List,	get,	patch,	update	and	delete	calls.
BigQuery is for BIG DATA
Column oriented (1)
Sample case : database of Books
ID	
(indexed)
title	
(indexed)
contents
1 The	Cat
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.2MB)
2 Cats	are	love
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.5MB)
3 Littul	Kittons
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	0.8MB)
select	id,	title	from	books	where	name	=	‘The	Cat’
Column oriented (2)
ID	
(indexed)
title	
(indexed)
contents
1 The	Cat
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.2MB)
2 Cats	are	love
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.5MB)
3 Littul	Kittons
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	0.8MB)
select	*	from	books	where	title	=	‘The	Cat’	
@RDBMS
index	(name)
hash	data
hash	data
hash	data
data in databaseIndexes
scanned data
Column oriented (3)
ID	
(indexed)
title	
(indexed)
contents
1 The	Cat
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.2MB)
2 Cats	are	love
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.5MB)
3 Littul	Kittons
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	0.8MB)
select	*	from	books	where	title	=	‘The	Cat’	
@BigQuery
data in database
scanned data
Column oriented (3)
ID	
(indexed)
title	
(indexed)
contents
1 The	Cat
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.2MB)
2 Cats	are	love
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.5MB)
3 Littul	Kittons
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	0.8MB)
select	*	from	books	where	title	=	‘The	Cat’	
@BigQuery
data in database
scanned data
Full-scan

ANYTIME!!
Column oriented (4)
ID	
(indexed)
title	
(indexed)
contents
1 The	Cat
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.2MB)
2 Cats	are	love
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.5MB)
3 Littul	Kittons
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	0.8MB)
select	*	from	books	where	title	=	‘The	Cat’	
@BigQuery
data in database
If your database is Tera-byte scale,
$5 per query !!!!
Column oriented (5)
ID	
(indexed)
title	
(indexed)
contents
1 The	Cat
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.2MB)
2 Cats	are	love
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.5MB)
3 Littul	Kittons
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	0.8MB)
select	id,	title	from	books	where	title	=	‘The	Cat’	
@RDBMS
index	(name)
hash	data
hash	data
hash	data
data in databaseIndexes
scanned data
Column oriented (6)
ID	
(indexed)
title	
(indexed)
contents
1 The	Cat
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.2MB)
2 Cats	are	love
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.5MB)
3 Littul	Kittons
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	0.8MB)
select	id,	title	from	books	where	title	=	‘The	Cat’	
@BigQuery
data in database
scanned data
Column oriented (6)
ID	
(indexed)
title	
(indexed)
contents
1 The	Cat
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.2MB)
2 Cats	are	love
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.5MB)
3 Littul	Kittons
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	0.8MB)
select	id,	title	from	books	where	title	=	‘The	Cat’	
@BigQuery
data in database
scanned data
Column
Oriented
It's really
dangerous!
Please,	Please	set	columns	in	queries.
Table division
Sample case : database of Books
select	id,	title	from	books	where	time	in	‘2016/06/17’
: : : :
ID	
(indexed)
title	
(indexed)
contents
time	
(indexed)
1 The	Cat
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.2MB)
2016/01/01	
00:00:00
2 Cats	are	love
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	1.5MB)
2016/01/01	
00:01:23
353485397 Littul	Kittons
Lorem	ipsum	dolor	sit	amet,	
consectetur	(...	0.8MB)
2016/06/17	
00:01:46
Table division (1)
index	(time)
hash	data
hash	data
hash	data
data in databaseIndexes
scanned data
: : : :
ID	
(indexed)
title	
(indexed)
contents
time	
(indexed)
1 The	Cat
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
2016/01/01	
00:00:00
2
Cats	are	
love
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
2016/01/01	
00:01:23
353485397
Littul	
Kittons
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
0.8MB)
2016/06/17	
00:01:46
select	id,	title	from	books	where	time	in	‘2016/06/17’	
@RDBMS
Table division (2)
data in database
scanned data
: : : :
ID	
(indexed)
title	
(indexed)
contents
time	
(indexed)
1 The	Cat
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
1.2MB)
2016/01/01	
00:00:00
2 Cats	are	love
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
1.5MB)
2016/01/01	
00:01:23
353485397
Littul	
Kittons
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
0.8MB)
2016/06/17	
00:01:46
select	id,	title	from	books	where	time	in	‘2016/06/17’	
@BigQuery
Huge size
Table division (2)
data in database
scanned data
: : : :
ID	
(indexed)
title	
(indexed)
contents
time	
(indexed)
1 The	Cat
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
1.2MB)
2016/01/01	
00:00:00
2 Cats	are	love
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
1.5MB)
2016/01/01	
00:01:23
353485397
Littul	
Kittons
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
0.8MB)
2016/06/17	
00:01:46
select	id,	title	from	books	where	time	in	‘2016/06/17’	
@BigQuery
Huge size
Table division (3)
ID	
(indexed)
title	
(indexed)
contents
time	
(indexed)
1 The	Cat
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
1.2MB)
2016/01/01	
00:00:00
2 Cats	are	love
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
1.5MB)
2016/01/01	
00:01:23
ID	
(indexed)
title	
(indexed)
contents
time	
(indexed)
353485397
Littul	
Kittons
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
0.8MB)
2016/06/17	
00:01:46
:
Tables
books_20160101
:
books_20160617
Divide	tables	for	each	day.
Table division (4)
ID	
(indexed)
title	
(indexed)
contents
time	
(indexed)
1 The	Cat
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
1.2MB)
2016/01/01	
00:00:00
2 Cats	are	love
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
1.5MB)
2016/01/01	
00:01:23
ID	
(indexed)
title	
(indexed)
contents
time	
(indexed)
353485397
Littul	
Kittons
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
0.8MB)
2016/06/17	
00:01:46
:
books_20160101
:
books_20160617
select	id,	title	from	books	where	time	in	‘2016/06/17’	
@BigQuery
Table division (5)
ID	
(indexed)
title	
(indexed)
contents
time	
(indexed)
1 The	Cat
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
1.2MB)
2016/01/01	
00:00:00
books_20160101
::
ID	
(indexed)
title	
(indexed)
contents
time	
(indexed)
353485397
The	Great	
Catsby
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
0.8MB)
2016/06/16	
00:01:46
books_20160616
select	id,	title	from	books		
where	time	in	‘2016/06/16	-	2016/06/17’	
@BigQuery
ID	
(indexed)
title	
(indexed)
contents
time	
(indexed)
353485397
Littul	
Kittons
Lorem	ipsum	dolor	sit	
amet,	consectetur	(...	
2016/06/17	
00:01:46
books_20160617
Table division (6)
select	id,	title	from	books		
where	time	in	‘2016/06/16	-	2016/06/17’	
@BigQuery
SELECT	id,	title	FROM		
			(	
									TABLE_DATE_RANGE(books_,		
																										TIMESTAMP(‘2016-06-16'),	
																										TIMESTAMP(‘2016-06-17')	
									)	
				)
Table division (7)
Other	ways	to	divide	tables.
Table	decorator	

		-	https://cloud.google.com/bigquery/table-decorators	
“TABLE_QUERY”	
		-	https://cloud.google.com/bigquery/query-reference
“Import	from	GCS	is	much	faster	than	from	local”	
		1.	put	data	into	GCS	(Google	Clould	Storage	≒	S3	??)	
		2.	import	the	data	from	GCS.
Other	tips.
BigQuery is
Fast
Easy
Cheap
if it is used properly.
BigQuery is
Fast
Easy
Cheap
if it is used properly.
Remember
“--dry_run”
Thank you!

More Related Content

PDF
Getting started with BigQuery
PPTX
Data Mesh at Nordea with Kafka and Hadoop
PPTX
bigquery.pptx
PDF
Google Cloud ベストプラクティス:Google BigQuery 編 - 01 : BigQuery とは?
PDF
BigQuery implementation
PDF
Google BigQuery
PDF
Big Query Basics
PPTX
End-to-end Data Governance with Apache Avro and Atlas
Getting started with BigQuery
Data Mesh at Nordea with Kafka and Hadoop
bigquery.pptx
Google Cloud ベストプラクティス:Google BigQuery 編 - 01 : BigQuery とは?
BigQuery implementation
Google BigQuery
Big Query Basics
End-to-end Data Governance with Apache Avro and Atlas

What's hot (20)

PDF
Introduction to Apache Beam
PPTX
Azure Cosmos DB のキホンと使いドコロ
PDF
Google Cloud Dataflow
PDF
Bigquery 101
PDF
BigQuery for Beginners
PDF
YugabyteDBを使ってみよう(NewSQL/分散SQLデータベースよろず勉強会 #1 発表資料)
PDF
IoT Architectures for Apache Kafka and Event Streaming - Industry 4.0, Digita...
PPTX
Introduction to using google colab
PDF
ビッグデータ処理データベースの全体像と使い分け
PDF
Google BigQuery クエリの処理の流れ - #bq_sushi
PDF
統計情報のリセットによるautovacuumへの影響について(第39回PostgreSQLアンカンファレンス@オンライン 発表資料)
PPTX
Avro Tutorial - Records with Schema for Kafka and Hadoop
PDF
Apache Arrow: High Performance Columnar Data Framework
PDF
Enterprise Knowledge Graph
PDF
Google Cloud ベストプラクティス:Google BigQuery 編 - 03 : パフォーマンスとコストの最適化
PPTX
Databricks for Dummies
PDF
自律型データベース Oracle Autonomous Database 最新情報
PDF
Data lineage and observability with Marquez - subsurface 2020
PDF
Memoizeの仕組み(第41回PostgreSQLアンカンファレンス@オンライン 発表資料)
PDF
Ist Daten-Liberalismus der richtige Weg?
Introduction to Apache Beam
Azure Cosmos DB のキホンと使いドコロ
Google Cloud Dataflow
Bigquery 101
BigQuery for Beginners
YugabyteDBを使ってみよう(NewSQL/分散SQLデータベースよろず勉強会 #1 発表資料)
IoT Architectures for Apache Kafka and Event Streaming - Industry 4.0, Digita...
Introduction to using google colab
ビッグデータ処理データベースの全体像と使い分け
Google BigQuery クエリの処理の流れ - #bq_sushi
統計情報のリセットによるautovacuumへの影響について(第39回PostgreSQLアンカンファレンス@オンライン 発表資料)
Avro Tutorial - Records with Schema for Kafka and Hadoop
Apache Arrow: High Performance Columnar Data Framework
Enterprise Knowledge Graph
Google Cloud ベストプラクティス:Google BigQuery 編 - 03 : パフォーマンスとコストの最適化
Databricks for Dummies
自律型データベース Oracle Autonomous Database 最新情報
Data lineage and observability with Marquez - subsurface 2020
Memoizeの仕組み(第41回PostgreSQLアンカンファレンス@オンライン 発表資料)
Ist Daten-Liberalismus der richtige Weg?
Ad

Similar to Big query - Command line tools and Tips - (MOSG) (20)

PPTX
Gcp github-bigquery
PDF
Hadoop Conf 2014 - Hadoop BigQuery Connector
PDF
Big query the first step - (MOSG)
PDF
GCP - GCE, Cloud SQL, Cloud Storage, BigQuery Basic Training
PDF
Big Data Analytics with Google BigQuery. GDG Summit Spain 2014
PDF
Big Data Analytics with Google BigQuery, by Javier Ramirez, datawaki, at Span...
PDF
Big query
PPTX
Intro to the Google Cloud for Developers
PDF
Big Query - Women Techmarkers (Ukraine - March 2014)
PDF
Executive Intro to BigQuery
PDF
Google BigQuery - Features & Benefits
PPTX
Data Science using Google Cloud BigQuery, Python and Power BI
PDF
Google I/O 2016 Recap - Google Cloud Platform News Update
PDF
Exploring BigData with Google BigQuery
PDF
Google cloud platform Introduction - 2014
ODP
Big Data Analytics with Google BigQuery. By Javier Ramirez. All your base Co...
PDF
Exploring Google APIs with Python
PDF
Intro to new Google cloud technologies: Google Storage, Prediction API, BigQuery
PDF
Google BigQuery is the future of Analytics! (Google Developer Conference)
PPTX
Building MuleSoft Applications with Google BigQuery Meetup 4
Gcp github-bigquery
Hadoop Conf 2014 - Hadoop BigQuery Connector
Big query the first step - (MOSG)
GCP - GCE, Cloud SQL, Cloud Storage, BigQuery Basic Training
Big Data Analytics with Google BigQuery. GDG Summit Spain 2014
Big Data Analytics with Google BigQuery, by Javier Ramirez, datawaki, at Span...
Big query
Intro to the Google Cloud for Developers
Big Query - Women Techmarkers (Ukraine - March 2014)
Executive Intro to BigQuery
Google BigQuery - Features & Benefits
Data Science using Google Cloud BigQuery, Python and Power BI
Google I/O 2016 Recap - Google Cloud Platform News Update
Exploring BigData with Google BigQuery
Google cloud platform Introduction - 2014
Big Data Analytics with Google BigQuery. By Javier Ramirez. All your base Co...
Exploring Google APIs with Python
Intro to new Google cloud technologies: Google Storage, Prediction API, BigQuery
Google BigQuery is the future of Analytics! (Google Developer Conference)
Building MuleSoft Applications with Google BigQuery Meetup 4
Ad

More from Soshi Nemoto (10)

PDF
CI : the first_step: Auto Testing with CircleCI - (MOSG)
PDF
Preparation study of_docker - (MOSG)
PDF
Making environment for_infrastructure_as_code
PDF
Fabric workshop(1) - (MOSG)
PDF
DevOps(4) : Ansible(2) - (MOSG)
PDF
DevOps(3) : Ansible - (MOSG)
PDF
DevOps(2) : Vagrant - (MOSG)
PDF
DevOps(1) : What's DevOps - (MOSG)
PDF
Instruction: dev environment
PDF
Why was your proposal rejected?
CI : the first_step: Auto Testing with CircleCI - (MOSG)
Preparation study of_docker - (MOSG)
Making environment for_infrastructure_as_code
Fabric workshop(1) - (MOSG)
DevOps(4) : Ansible(2) - (MOSG)
DevOps(3) : Ansible - (MOSG)
DevOps(2) : Vagrant - (MOSG)
DevOps(1) : What's DevOps - (MOSG)
Instruction: dev environment
Why was your proposal rejected?

Recently uploaded (20)

PDF
Empathic Computing: Creating Shared Understanding
PPT
Teaching material agriculture food technology
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PPTX
Big Data Technologies - Introduction.pptx
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
Approach and Philosophy of On baking technology
PDF
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
PDF
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PPTX
A Presentation on Artificial Intelligence
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Empathic Computing: Creating Shared Understanding
Teaching material agriculture food technology
Building Integrated photovoltaic BIPV_UPV.pdf
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
Per capita expenditure prediction using model stacking based on satellite ima...
Big Data Technologies - Introduction.pptx
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
Approach and Philosophy of On baking technology
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
A Presentation on Artificial Intelligence
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Understanding_Digital_Forensics_Presentation.pptx
Dropbox Q2 2025 Financial Results & Investor Presentation
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
NewMind AI Weekly Chronicles - August'25 Week I
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx

Big query - Command line tools and Tips - (MOSG)