You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by "dinggege1024 (via GitHub)" <gi...@apache.org> on 2023/05/05 03:21:42 UTC

[GitHub] [doris] dinggege1024 opened a new issue, #19297: [Enhancement] ADD bitmap function: bitmap_distinct

dinggege1024 opened a new issue, #19297:
URL: https://github.com/apache/doris/issues/19297

   ### Search before asking
   
   - [X] I had searched in the [issues](https://github.com/apache/doris/issues?q=is%3Aissue) and found no similar issues.
   
   
   ### Description
   
   I need bitmap_distinct for data handling.
   
   My requirement is to use the features of Bitmap itself to deduplicate columns and obtain the unique column values.
   
   Current situation(Reasons for dissatisfaction):
   ```hiveql
           SELECT
               dt
               ,bitmap_to_string(bitmap_union(to_bitmap(user_id)))
           FROM
               mytable
           GROUP BY
               dt
   ``` 
   it return one column for user_id
   ![image](https://user-images.githubusercontent.com/109070189/236370480-76d22ff6-37f7-4ab1-93e1-eb121b143ab8.png)
   
   Expected:
   ```hiveql
           SELECT
               dt
               ,bitmap_distinct(to_bitmap(user_id))
           FROM
               mytable
           GROUP BY
               dt
   ``` 
   ![image](https://user-images.githubusercontent.com/109070189/236370769-5f8c0e30-2036-4e33-bb24-ab0f0079f071.png)
   
   ### Solution
   
    Doris Java UDF
   
   ### Are you willing to submit PR?
   
   - [X] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] LemonLiTree commented on issue #19297: [Enhancement] Support bitmap function: bitmap_distinct

Posted by "LemonLiTree (via GitHub)" <gi...@apache.org>.
LemonLiTree commented on issue #19297:
URL: https://github.com/apache/doris/issues/19297#issuecomment-1538117968

   Actually this is a table functions, I think it is possible to add a case to this document :https://doris.apache.org/docs/dev/advanced/orthogonal-bitmap-manual/
   Would you like to create a PR to supplement?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] dinggege1024 commented on issue #19297: [Enhancement] Support bitmap function: bitmap_distinct

Posted by "dinggege1024 (via GitHub)" <gi...@apache.org>.
dinggege1024 commented on issue #19297:
URL: https://github.com/apache/doris/issues/19297#issuecomment-1537915723

   > 
   
   Tks, it works, should add this func into bitmap func docs?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] LemonLiTree commented on issue #19297: [Enhancement] Support bitmap function: bitmap_distinct

Posted by "LemonLiTree (via GitHub)" <gi...@apache.org>.
LemonLiTree commented on issue #19297:
URL: https://github.com/apache/doris/issues/19297#issuecomment-1537076395

   I think you can solve this problem using explode_bitmap
   https://doris.apache.org/zh-CN/docs/dev/sql-manual/sql-functions/table-functions/explode-bitmap


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] dinggege1024 commented on issue #19297: [Enhancement] Support bitmap function: bitmap_distinct

Posted by "dinggege1024 (via GitHub)" <gi...@apache.org>.
dinggege1024 commented on issue #19297:
URL: https://github.com/apache/doris/issues/19297#issuecomment-1538450739

   > Actually this is a table functions, I think it is possible to add a case to this document :https://doris.apache.org/docs/dev/advanced/orthogonal-bitmap-manual/ Would you like to create a PR to supplement?
   
   ok


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


Re: [I] [Enhancement] Support bitmap function: bitmap_distinct [doris]

Posted by "morningman (via GitHub)" <gi...@apache.org>.
morningman closed issue #19297: [Enhancement] Support bitmap function: bitmap_distinct
URL: https://github.com/apache/doris/issues/19297


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org