[
https://issues.jboss.org/browse/TEIID-7?page=com.atlassian.jira.plugin.sy...
]
Steven Hawkins resolved TEIID-7.
--------------------------------
Resolution: Partially Completed
Problem 1/2 have already been addressed by other issues. Setting explicit precision and
scale is a broader issue. Currently the type system is too simplistic to allow for
additional facets.
Control of BigDecimal precision and scale
-----------------------------------------
Key: TEIID-7
URL:
https://issues.jboss.org/browse/TEIID-7
Project: Teiid
Issue Type: Bug
Components: Query Engine
Affects Versions: 9.x
Reporter: Jerry Helbling
Priority: Minor
Fix For: 8.0
Problem 1: The parser defaults to parsing literals that look like bigdecimal as doubles,
which have no scale.
Workaround (which is on devcentral): You can avoid the above conversions by wrapping the
values in a convert in the query (example: "convert('123.00', BigDecimal
)").
A better fix is update the parser to look for loss of scale information and to use the
bigdecimal type instead.
Problem 2: default division behavior JBEDSP-305
Problem 3: No explicit control via the parser
It would be good to provide explicit precision and scale via "convert(xxx,
BigDecimal(10, 2))" - side note bigdecimal is a bad name for this type. it should
really just be decimal
Reference: This is related to Issue Tracker Issue 175485.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see:
http://www.atlassian.com/software/jira