Qiita Teams that are logged in
You are not logged in to any team

Log in to Qiita Team
Community
OrganizationAdvent CalendarQiitadon (β)
Service
Qiita JobsQiita ZineQiita Blog
Help us understand the problem. What is going on with this article?

BigQueryで虚無からSQLだけでデータを作る

More than 1 year has passed since last update.

テストデータを作るときに便利!

カラム名付きリレーション

UNNESTARRAYSTRUCTを使えば、カラム名付きリレーションを作り出せる。

#standardSQL
SELECT * FROM UNNEST(ARRAY<STRUCT<id INT64, name STRING>>
[
  (1, 'COMPパウダー')
  , (2, 'COMPグミ')
  , (3, 'COMPドリンク')
])
id name
1 1 COMPパウダー
2 2 COMPグミ
3 3 COMPドリンク
tamanobi
Vim/Python/C++/Common Lisp/PHP/JavaScript/データ分析/機械学習/画像解析/NEM
admin-guild
「Webサービスの運営に必要なあらゆる知見」を共有できる場として作られた、運営者のためのコミュニティです。
https://admin-guild.slack.com
Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away