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

[SPARK-10980] [SQL] fix bug in create Decimal #9014

Closed
wants to merge 1 commit into from

Conversation

davies
Copy link
Contributor

@davies davies commented Oct 7, 2015

The created decimal is wrong if using Decimal(unscaled, precision, scale) with unscaled > 1e18 and and precision > 18 and scale > 0.

This bug exists since the beginning.

@SparkQA
Copy link

SparkQA commented Oct 7, 2015

Test build #43345 has finished for PR 9014 at commit d6cbdd2.

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

asfgit pushed a commit that referenced this pull request Oct 7, 2015
The created decimal is wrong if using `Decimal(unscaled, precision, scale)` with unscaled > 1e18 and and precision > 18 and scale > 0.

This bug exists since the beginning.

Author: Davies Liu <davies@databricks.com>

Closes #9014 from davies/fix_decimal.

(cherry picked from commit 37526ac)
Signed-off-by: Davies Liu <davies.liu@gmail.com>
@asfgit asfgit closed this in 37526ac Oct 7, 2015
asfgit pushed a commit that referenced this pull request Oct 7, 2015
The created decimal is wrong if using `Decimal(unscaled, precision, scale)` with unscaled > 1e18 and and precision > 18 and scale > 0.

This bug exists since the beginning.

Author: Davies Liu <davies@databricks.com>

Closes #9014 from davies/fix_decimal.

(cherry picked from commit 37526ac)
Signed-off-by: Davies Liu <davies.liu@gmail.com>

Conflicts:
	sql/catalyst/src/main/scala/org/apache/spark/sql/types/Decimal.scala
asfgit pushed a commit that referenced this pull request Oct 7, 2015
The created decimal is wrong if using `Decimal(unscaled, precision, scale)` with unscaled > 1e18 and and precision > 18 and scale > 0.

This bug exists since the beginning.

Author: Davies Liu <davies@databricks.com>

Closes #9014 from davies/fix_decimal.

(cherry picked from commit 37526ac)
Signed-off-by: Davies Liu <davies.liu@gmail.com>

Conflicts:
	sql/catalyst/src/main/scala/org/apache/spark/sql/types/Decimal.scala
asfgit pushed a commit that referenced this pull request Oct 7, 2015
The created decimal is wrong if using `Decimal(unscaled, precision, scale)` with unscaled > 1e18 and and precision > 18 and scale > 0.

This bug exists since the beginning.

Author: Davies Liu <davies@databricks.com>

Closes #9014 from davies/fix_decimal.

(cherry picked from commit 37526ac)
Signed-off-by: Davies Liu <davies.liu@gmail.com>

Conflicts:
	sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/types/decimal/Decimal.scala
@davies
Copy link
Contributor Author

davies commented Oct 7, 2015

Merged into master and 1.2, 1.3, 1.4, 1.5 branches.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants