【问题标题】:How to Set Big Query Require Partition Filter in BQ Commandline With Ingestion Partition Tables如何使用摄取分区表在 BQ 命令行中设置 Big Query Require Partition Filter
【发布时间】:2018-12-12 10:53:07
【问题描述】:

我正在尝试在创建表后向表中添加分区过滤器要求。由于this post 和 kennethmac2000,我知道可以为按列分区的表执行此操作,但我这个解决方案似乎不适用于摄取日期分区表。

一开始我试过

bq update --require_partition_filter project:dataset.table

然后我尝试了

bq update --time_partitioning_type DAY --require_partition_filter project:dataset.table

两者都会导致...

UpdateTable() got an unexpected keyword argument 'range_partitioning'

我们将不胜感激。

【问题讨论】:

标签: google-bigquery


【解决方案1】:

在 CLI 版本上对我来说很好用:

$ gcloud --version
Google Cloud SDK 215.0.0
beta 2018.07.16
bq 2.0.34
core 2018.09.04
gsutil 4.33

$ bq update --require_partition_filter --time_partitioning_type=DAY grey-sort-challenge:afl_ml.partition_filter_test
Table 'grey-sort-challenge:afl_ml.partition_filter_test' successfully updated.

【讨论】:

  • 我不认为微小的版本差异很重要,但这是 gcloud --version: Google Cloud SDK 225.0.0, bq 2.0.37, core 2018.11.09, gsutil 4.34 的结果跨度>
  • 对不起,我不知道你做错了什么斯蒂芬。但它对我来说很好。
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 2017-01-08
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2020-03-23
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多