Use of the _PARTITIONDATE vs. the _PARTITIONTIME pseudo-columns in BigQuery -


in official best-practices found:

partitioning tables date , querying relevant partition; example, _partitiondate="2017-01-01" scans january 1, 2017 partition

and started using _partitiondate pseudo-column quite lot, find easier write queries way, in contrast _partitiontime column , applying timestamp() function onto date, shown in example:

where _partitiontime = timestamp('2016-03-28')

i wondering if should continue usage of _partitiondate - unable find more documentation on it. also, in contrast _partitiontime not syntax-highlighted in web-based bigquery sql-editor.

is official way favor _partitiontime on _parttiondate?

_partitiondate isn't documented, because doesn't correspond feature has been released. should use _partitiontime unless announce new feature in release notes.

where _partitiontime = timestamp('2016-03-28') 

is same as

where _partitiontime = '2016-03-28' 

the _partitiontime column timestamp, string literal on right side of latter example coerced timestamp. in terms of syntax highlighting, current ui has limitations of recognizing built-in functions, upcoming ui refresh expected address that.


Comments

Popular posts from this blog

angular - Ionic slides - dynamically add slides before and after -

minify - Minimizing css files -

Add a dynamic header in angular 2 http provider -