Using the obsolete BigQuery syntax, we must use the exact_count_distinct function if we want to have the exact number of different values for the field.
With the standard SQL 2011 syntax , it is interesting whether the “ count (excellent myfield)” will always return the exact number of different values if I do not select the option “Use legacy SQL”.
COUNT(DISTINCT input) gives the exact amount in standard SQL.
COUNT(DISTINCT input)
, COUNT(DISTINCT input) , EXACT_COUNT_DISTINCT(input) BigQuery SQL, , .
EXACT_COUNT_DISTINCT(input)
SQL .
APPROX_COUNT_DISTINCT ( ):
COUNT(DISTINCT input) -APPROX_COUNT_DISTINCT(input) -
APPROX_COUNT_DISTINCT(input)
Source: https://habr.com/ru/post/1665927/More articles:Connect Python to H2 - python-2.7Play Framework: Unable to load native JNotify library - playframeworkCompute active custom metrics for Firebase Analytics in BigQuery - firebase-analyticspdfmake не соответствует размеру позиции страницы - javascriptAccessing SMB2.1 or SMB3 resources from java? - javaPandas - find the longest stretch without Nan values - pythonThe host is not resolved on the local network - androidDownload PDF using Cross Browser compatible JavaScript - javascriptDecoding a multi-track JSON tree to a multi-faceted tree F # - jsonExtracting facts as a matrix in Prolog - matrixAll Articles