Kbase P117220: Decimals are truncated to integers when multiplying decimal fields in a query using the ODBC driver
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  8/16/2006 |
|
Status: Unverified
FACT(s) (Environment):
Progress 9.1x
OpenEdge 10.x
SYMPTOM(s):
Decimals are truncated to integers when multiplying decimal fields in a query
Using the DataDirect SQL-92 ODBC driver
Example of query:
select balance * balance from pub.customer;
The SQL-WIDTH of the decimal fields is set to 38.
The problem does not occur in every ODBC tool.
It occurs from the MS SQL Server DTS package
It does not occur from WinSQL
It can also be reproduced from a JDBC client.
The result is correct using the OpenEdge 10.1A01 ODBC/JDBC drivers
CAUSE:
Bug# 20060321-009
FIX:
There are 3 ways to solve the problem:
1- Upgrade to OpenEdge 10.1A01 or later.
Since the 10.1A ODBC/JDBC drivers can only connect to 10.1A database, the server and the clients need to be upgraded.
2- Decrease the SQL-WIDTH of the Decimal fields to 17.
This can be achieved from the Data Dictionary.
3- Change all the queries with the reformatting commands e.g. fn CONVERT etc.
Ex.: select { fn CONVERT(balance * balance, SQL_DECIMAL) } from pub.customer