Getting “Query too large” in BigQuery

后端 未结 1 798
旧巷少年郎
旧巷少年郎 2020-12-20 18:41

I am storing event data in BigQuery, partitioned by day - one table per day. The following query failed:

select count(distinct event) 
from TABLE_DATE_RANGE(         


        
1条回答
  •  温柔的废话
    2020-12-20 19:06

    "Query too large" in this case means that the TABLE_RANGE is getting expanded internally to too many tables, generating an internal query that is too large to be processed.

    This has 2 workarounds:

    • Query less tables (could you aggregate these tables into a bigger one?).
    • Wait until the BQ team solves this issue internally. Instead of using a workaround, you should be able to run this query unchanged. Just not today :).

    0 讨论(0)
提交回复
热议问题