Skip to content

[SPARK-27879][SQL] Add support for bit_and and bit_or aggregates#26155

Closed
yaooqinn wants to merge 3 commits into
apache:masterfrom
yaooqinn:SPARK-27879
Closed

[SPARK-27879][SQL] Add support for bit_and and bit_or aggregates#26155
yaooqinn wants to merge 3 commits into
apache:masterfrom
yaooqinn:SPARK-27879

Conversation

@yaooqinn

Copy link
Copy Markdown
Member

What changes were proposed in this pull request?

bit_and(expression) -- The bitwise AND of all non-null input values, or null if none
bit_or(expression) -- The bitwise OR of all non-null input values, or null if none

More details:
https://www.postgresql.org/docs/9.3/functions-aggregate.html

Why are the changes needed?

Postgres, Mysql and many other popular db support them.

Does this PR introduce any user-facing change?

add two bit agg

How was this patch tested?

add ut

@SparkQA

SparkQA commented Oct 18, 2019

Copy link
Copy Markdown

Test build #112250 has finished for PR 26155 at commit b6c246e.

  • This patch fails Spark unit tests.
  • This patch merges cleanly.
  • This patch adds the following public classes (experimental):
  • case class BitAndAgg(child: Expression) extends DeclarativeAggregate with ExpectsInputTypes
  • case class BitOrAgg(child: Expression) extends DeclarativeAggregate with ExpectsInputTypes

@yaooqinn

Copy link
Copy Markdown
Member Author

cc @cloud-fan @wangyum, thanks

@SparkQA

SparkQA commented Oct 18, 2019

Copy link
Copy Markdown

Test build #112266 has finished for PR 26155 at commit 58b99e9.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@cloud-fan

Copy link
Copy Markdown
Contributor

LGTM

@SparkQA

SparkQA commented Oct 21, 2019

Copy link
Copy Markdown

Test build #112355 has finished for PR 26155 at commit e91c364.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@cloud-fan

Copy link
Copy Markdown
Contributor

thanks, merging to master!

@cloud-fan cloud-fan closed this in 5b4d917 Oct 21, 2019
@yaooqinn yaooqinn deleted the SPARK-27879 branch October 21, 2019 06:35
@yaooqinn yaooqinn restored the SPARK-27879 branch October 21, 2019 06:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants