Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add bitmapContains #5535

Merged
merged 4 commits into from Jun 14, 2019
Merged

Add bitmapContains #5535

merged 4 commits into from Jun 14, 2019

Conversation

yuzhichang
Copy link
Contributor

I hereby agree to the terms of the CLA available at: https://yandex.ru/legal/cla/?lang=en

For changelog. Remove if this is non-significant change.

Category (leave one):

  • New Feature

Short description (up to few sentences):
bitmapContains implementation. It's 2x faster than bitmapHasAny if the second bitmap contains one element.

SELECT count(*) FROM trips WHERE bitmapHasAny((SELECT groupBitmapState(id) FROM trips WHERE pickup_datetime>'2017-06-24 00:00:00'), bitmapBuild([id]));

SELECT count(*) FROM trips WHERE bitmapContains((SELECT groupBitmapState(id) FROM trips WHERE pickup_datetime>'2017-06-24 00:00:00'), CAST(id, 'UInt32'));

@alexey-milovidov alexey-milovidov merged commit 9b727d2 into ClickHouse:master Jun 14, 2019
@CurtizJ CurtizJ added the pr-feature Pull request with new product feature label Jun 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr-feature Pull request with new product feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants