Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Love at first query
Search
DouEnergy
August 02, 2023
Programming
1
220
Love at first query
exploring SQL with DuckDB
DouEnergy
August 02, 2023
Tweet
Share
More Decks by DouEnergy
See All by DouEnergy
The Last Gedi
douenergy
0
57
Other Decks in Programming
See All in Programming
複雑なドメインに挑む.pdf
yukisakai1225
5
960
More Approvers for Greater OSS and Japan Community
tkikuc
1
110
AIレビュアーをスケールさせるには / Scaling AI Reviewers
technuma
2
240
HTMLの品質ってなんだっけ? “HTMLクライテリア”の設計と実践
unachang113
3
1.9k
Swift Updates - Learn Languages 2025
koher
2
410
【第4回】関東Kaggler会「Kaggleは執筆に役立つ」
mipypf
0
1k
Honoアップデート 2025年夏
yusukebe
1
910
Laravel Boost 超入門
fire_arlo
2
190
Claude Codeで実装以外の開発フロー、どこまで自動化できるか?失敗と成功
ndadayo
4
1.9k
Namespace and Its Future
tagomoris
6
690
オープンセミナー2025@広島「君はどこで動かすか?」アンケート結果
satoshi256kbyte
0
240
Vue・React マルチプロダクト開発を支える Vite
andpad
0
110
Featured
See All Featured
For a Future-Friendly Web
brad_frost
179
9.9k
GitHub's CSS Performance
jonrohan
1032
460k
Done Done
chrislema
185
16k
The Art of Programming - Codeland 2020
erikaheidi
55
13k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
44
2.5k
Practical Orchestrator
shlominoach
190
11k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
358
30k
What's in a price? How to price your products and services
michaelherold
246
12k
Building a Scalable Design System with Sketch
lauravandoore
462
33k
Bootstrapping a Software Product
garrettdimon
PRO
307
110k
It's Worth the Effort
3n
187
28k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Transcript
None
None
None
None
DouEnergy
None
SQLite for analytics
None
None
We all love Postgres
S3, malloc for the Internet
Building and operating a pretty big storage system called S3
We all love AWS S3
None
How many of you can set up a Postgres on
your laptop to analyze a CSV(JSON, Parquet) on AWS S3?
And...
In less 3 minutes
Or
DuckDB-wasm
just 3 seconds
SELECT * FROM 'https://r2duck2.douenergy.com/central-park-w eather.csv';
Demo 1
CREATE TABLE R2Weather AS FROM 'https://r2duck2.douenergy.com/central-park- weather.csv';
Annual average of maximum temperature ? (每一年的單日最高溫平均)
SELECT EXTRACT(YEAR FROM DATE) AS year, AVG(TMAX) as average_max_temp FROM
R2weather GROUP BY year ORDER BY year;
Rolling average of the maximum temperature over the last 7
days for each date?(過去七日的最高溫平均)
SELECT DATE, TMAX, AVG(TMAX) OVER sevenday AS rolling_7_day_avg FROM R2weather
WINDOW sevenday AS(ORDER BY DATE ROWS BETWEEN 6 PRECEDING AND CURRENT ROW) LIMIT 20;
Average maximum temperature? precipitation(降雨量) 0.1 < precipitation < 0.2 0.4
< precipitation
SELECT COUNT(*) FILTER (WHERE PRCP BETWEEN 0.1 AND 0.2) low_days,
AVG(TMAX) FILTER (WHERE PRCP BETWEEN 0.1 AND 0.2) low_prcp_temp, COUNT(*) FILTER (WHERE 0.4 < PRCP) high_days, AVG(TMAX) FILTER (WHERE 0.4 < PRCP) high_prcp_temp FROM R2Weather;
None
None
None
None
None
None
None
None
None
None
None
None
None
Apache Arrow
Benchmark
Demo 2
葛來分多 加10分
葛來分多 再加10分
None
Two month ago 🔥
Duck Arts Defence 🦆🪄
Duck Arts Defence 🦆🪄
None
None
You may say I'm a SQLer But I'm not the
only one. I hope someday you'll join us.
Thanks