Article Outline
カスタムクエリ
TOC
Collection Outline
[BIGQUERY] 分析入門
[BIGQUERY] SQL
■ 句(節)
■ 演算子
■ BigQuery特有
■ 関数
- approx_count_distinct() - 集計近似
- coalesce()
- countif()
- extract()
- greatest()
- ifnull()
- last_day()
- lead() / lag()
- left() / right()
- lower()
- nullif()
- parse_date()
- row_number() - 番号付
- safe_cast()
- split()
- st_distance()
- nth_value()
- first_value() / last_value()
- percentile_()
データ型
■ エラー
- error
- Resources exceeded during query execution: Not enough resources for query planning - too many subqueries or query is too complex
[BIGQUERY] ADVANCE
[BIGQUERY] ML
[BIGQUERY] DS
■ DS100ノック
■
[BIGQUERY] GA
|| カスタムクエリ
パラメータ | 用途 |
---|---|
@DS_USER_EMAIL | ログイン ユーザーのメールアドレスを取得します。 |
-- メール パラメータの例:
select
*
from
Sales
where
sales-rep-email = @DS_USER_EMAIL
;
|
#standardSQL
SELECT
word,
word_count
FROM
`bigquery-public-data.samples.shakespeare`
WHERE
corpus = @corpus --
AND word_count >= @min_word_count --
ORDER BY
word_count DESC;
|| REFERENCE
- カスタムクエリでパラメータを使用する - Dataportal Help
- パラメータ - Dataportal Help
- パラメータ化されたクエリの実行 - Google Cloud