Divyanshu Sen
Divyanshu Sen

Reputation: 131

The query is too large. The maximum standard SQL query length is 1024.00K characters, including comments and white space characters

I am running this query in bigquery where I am selecting the data of mobile_ids which match in the array of strings. But when I increase the number of size of array of strings, it shows error:

Error: The query is too large. The maximum standard SQL query length is 1024.00K characters, including comments and white space characters.

My code is:

SELECT *,EXTRACT(HOUR FROM TIMESTAMP(UTC_TIMESTAMP) AT TIME ZONE "Asia/Kolkata") FROM \`mytable\` WHERE (EXTRACT(HOUR FROM TIMESTAMP(UTC_TIMESTAMP) AT TIME ZONE "Asia/Kolkata") <=6 OR EXTRACT(HOUR FROM TIMESTAMP(UTC_TIMESTAMP) AT TIME ZONE "Asia/Kolkata") >=22) AND mobile_id in UNNEST(${array_of_strings}) ;

Array of strings is["mobile_Id1","mobile_id_2"........]

Upvotes: 4

Views: 4060

Answers (0)

Related Questions