Skip to content

[Enhancement] Support bitmap function: bitmap_distinct #19297

@dinggege1024

Description

@dinggege1024

Search before asking

  • I had searched in the issues 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):

        SELECT
            dt
            ,bitmap_to_string(bitmap_union(to_bitmap(user_id)))
        FROM
            mytable
        GROUP BY
            dt

it return one column for user_id
image

Expected:

        SELECT
            dt
            ,bitmap_distinct(to_bitmap(user_id))
        FROM
            mytable
        GROUP BY
            dt

image

Solution

Doris Java UDF

Are you willing to submit PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions