@@ -3670,14 +3670,38 @@ bits28
type of the field is a BigQuery INT64, but logically the integer
represents an array of bits, with each 1 indicating a day where the given clients
was active and each 0 indicating a day where the client was inactive.
-retention (UDF)
-Return a nested struct providing booleans indicating whether a given client
-was active various time periods based on the passed bit pattern.
+from_string (UDF)
+Convert a string representing individual bits into an INT64.
+Implementation based on https://stackoverflow.com/a/51600210/1260237
+See detailed docs for the bits28 suite of functions:
+https://docs.telemetry.mozilla.org/cookbooks/clients_last_seen_bits.html#udf-reference
Parameters
INPUTS
-bits INT64, submission_date DATE
+
-Source | Edit
+OUTPUTS
+
+Source | Edit
+days_since_seen (UDF)
+Return the position of the rightmost set bit in an INT64 bit pattern.
+To determine this position, we take a bitwise AND of the bit pattern and
+its complement, then we determine the position of the bit via base-2
+logarithm; see https://stackoverflow.com/a/42747608/1260237
+See detailed docs for the bits28 suite of functions:
+https://docs.telemetry.mozilla.org/cookbooks/clients_last_seen_bits.html#udf-reference
+SELECT
+ mozfun.bits28.days_since_seen(18)
+-- >> 1
+
+Parameters
+INPUTS
+
+OUTPUTS
+
+Source | Edit
to_string (UDF)
Convert an INT64 field into a 28-character string representing
the individual bits.
@@ -3690,7 +3714,7 @@ to_string (UDF)
-- '0000000000000000000000000010',
-- '0000000000000000000000000011']
-Parameters
+Parameters
INPUTS
@@ -3706,7 +3730,7 @@ active_in_range (UDF)
start_offset
.
See detailed docs for the bits28 suite of functions:
https://docs.telemetry.mozilla.org/cookbooks/clients_last_seen_bits.html#udf-reference
-Parameters
+Parameters
INPUTS
bits INT64, start_offset INT64, n_bits INT64
@@ -3714,6 +3738,18 @@ Parameters
Source | Edit
+to_dates (UDF)
+Convert a bit pattern into an array of the dates is represents.
+See detailed docs for the bits28 suite of functions:
+https://docs.telemetry.mozilla.org/cookbooks/clients_last_seen_bits.html#udf-reference
+Parameters
+INPUTS
+bits INT64, submission_date DATE
+
+OUTPUTS
+
+Source | Edit
range (UDF)
Return an INT64 representing a range of bits from a source bit pattern.
The start_offset must be zero or a negative number indicating an offset from
@@ -3731,7 +3767,7 @@
range (UDF)
WHERE
submission_date > '2020-01-01'
-Parameters
+Parameters
INPUTS
bits INT64, start_offset INT64, n_bits INT64
@@ -3739,50 +3775,14 @@ Parameters
Source | Edit
-to_dates (UDF)
-Convert a bit pattern into an array of the dates is represents.
-See detailed docs for the bits28 suite of functions:
-https://docs.telemetry.mozilla.org/cookbooks/clients_last_seen_bits.html#udf-reference
-Parameters
-INPUTS
-bits INT64, submission_date DATE
-
-OUTPUTS
-
-Source | Edit
-days_since_seen (UDF)
-Return the position of the rightmost set bit in an INT64 bit pattern.
-To determine this position, we take a bitwise AND of the bit pattern and
-its complement, then we determine the position of the bit via base-2
-logarithm; see https://stackoverflow.com/a/42747608/1260237
-See detailed docs for the bits28 suite of functions:
-https://docs.telemetry.mozilla.org/cookbooks/clients_last_seen_bits.html#udf-reference
-SELECT
- mozfun.bits28.days_since_seen(18)
--- >> 1
-
-Parameters
-INPUTS
-
-OUTPUTS
-
-Source | Edit
-from_string (UDF)
-Convert a string representing individual bits into an INT64.
-Implementation based on https://stackoverflow.com/a/51600210/1260237
-See detailed docs for the bits28 suite of functions:
-https://docs.telemetry.mozilla.org/cookbooks/clients_last_seen_bits.html#udf-reference
+retention (UDF)
+Return a nested struct providing booleans indicating whether a given client
+was active various time periods based on the passed bit pattern.
Parameters
INPUTS
-
-OUTPUTS
-INT64
+bits INT64, submission_date DATE
-Source | Edit
+Source | Edit
diff --git a/mozfun/bytes/index.html b/mozfun/bytes/index.html
index c56dafa3a76..a82001b7ba2 100644
--- a/mozfun/bytes/index.html
+++ b/mozfun/bytes/index.html
@@ -2800,11 +2800,11 @@
-
-
- bit_pos_to_byte_pos (UDF)
+
+ zero_right (UDF)
-