forked from CUBRID/cubrid-manual
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Change the 'Result of NUMERIC Type Operation' simply (CUBRID#416)
http://jira.cubrid.org/browse/CUBRIDMAN-110 http://jira.cubrid.org/browse/CBRD-24815 Change the contents of 'N(P1, S1) / N(P2, S2)' as below. - The content is the same, but change the description to a formula. | Operation | Maximum Precision | Maximum Scale | |-----------------------|-----------------------------------------|---------------| | N(p1, s1) + N(p2, s2) | max(p1 - s1, p2 - s2) + max(s1, s2) + 1 | max(s1, s2) | | N(p1, s1) - N(p2, s2) | max(p1 - s1, p2 - s2) + max(s1, s2) | max(s1, s2) | | N(p1, s1) * N(p2, s2) | p1 + p2 + 1 | s1 + s2 | | N(p1, s1) / N(p2, s2) | Pt = (p1 - s1) + s2 + max(9, max(s1, s2))<br /> Pt = (Pt > 38) ? 38 : Pt | St = max(9, max(s1, s2))<br /> St = (Pt > 38) ? min(9, St - (Pt - 38)) : St | https://www.cubrid.org/manual/en/11.2/sql/function/arithmetic_op.html#numeric-data-type-op-and-conversion
- Loading branch information
Showing
2 changed files
with
24 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters