Skip to main content

orthogonal_bitmap_intersect_count

Description​

The ORTHOGONAL_BITMAP_INTERSECT_COUNT function returns the number of elements in the set after performing an intersection calculation on the Bitmap expression.

Syntax​

ORTHOGONAL_BITMAP_INTERSECT_COUNT(<bitmap_column>, <column_to_filter>, <filter_values>)

Parameters​

ParametersDescription
<bitmap_column>The Bitmap type expression needs to be obtained
<column_to_filter>Optional. The dimension column that needs to be filtered
<filter_values>Optional. A variable-length parameter, used to filter different values of the dimension column

Return Value​

Returns a value of type BIGINT.

Example​

select orthogonal_bitmap_intersect_count(members, tag_group, 1150000, 1150001, 390006) from tag_map where  tag_group in ( 1150000, 1150001, 390006);
+-------------------------------------------------------------------------------------+
| orthogonal_bitmap_intersect_count(`members`, `tag_group`, 1150000, 1150001, 390006) |
+-------------------------------------------------------------------------------------+
| 0 |
+-------------------------------------------------------------------------------------+