Consultor Eletrônico



Kbase P52254: Getting error 1438 when loading .d into ORACLE
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   12/12/2003
Status: Unverified

FACT(s) (Environment):

Progress 9.1x

FACT(s) (Environment):

Oracle DataServer

SYMPTOM(s):

Getting error 1438 when loading .d into ORACLE table

load fails with the generation of a .e file

Value larger than specified precision allows for a column (1438)

Existing DF file

ADD FIELD "AMOUNT" OF "PROGRESS" AS decimal
FORMAT "->>>9.99"
INITIAL ?
POSITION 2
DECIMALS 2
ORDER 1050
MANDATORY
FOREIGN-POS 5
FOREIGN-NAME "AMOUNT"
FOREIGN-TYPE "NUMBER"
FOREIGN-MAXIMUM 6 <<<<<<--------------
DSRVR-PRECISION 6
FIELD-MISC12 2
FIELD-MISC13 22
FIELD-MISC14 1

.SQL created on the ORACLE Side

CREATE TABLE progress (
amount number(6,2) NOT NULL); <<<<<<--------------

CAUSE:

The data that is being inserted (via the load) into the column is larger than the defined length of the column within ORACLE.

Field (FOREIGN-MAXIMUM) within the schema holder DF displays the length of the column within ORACLE.

FIX:

Change column AMOUNT to
amount number(7,2) NOT NULL

After this change is made within ORACLE, repull the new table schema back into schema holder.

A DF dump of the new schema shows:
ADD FIELD "AMOUNT" OF "PROGRESS" AS decimal
FORMAT "->>>9.99"
INITIAL ?
POSITION 2
DECIMALS 2
ORDER 1060
MANDATORY
FOREIGN-POS 6
FOREIGN-NAME "AMOUNT"
FOREIGN-TYPE "NUMBER"
FOREIGN-MAXIMUM 7 <<<<<<--------------
DSRVR-PRECISION 7
FIELD-MISC12 2
FIELD-MISC13 22
FIELD-MISC14 1