Page 1 of 1

exception error decimal overflow has occurred during multipl

PostPosted: Wed Nov 14, 2018 6:10 pm
by rakeshsneha1212
Hi All,

I am trying to unload data from the DB2 table, I am getting decimal overflow error for one of the record which has values shown below.

SQL query
select
CAST(DECIMAL( F.QTY_SH_RECVD_SUOM* E.PRICE_PO ,13, 4)
AS CHAR(20)),


F.QTY_SH_RECVD_SUOM - declared as decimal(15,4) not null
E.PRICE_PO - declared as decimal(15,5,) not null

Below are the values for the particular record which is giving me an error
SELECT
CAST(DECIMAL(1190720.0000 * 1.01800,13,4) AS CHAR(20))
FROM SYSIBM.SYSDUMMY1

Just want to understand why is it failing only for this particular record.

Thanks,
Rakesh MS

Re: exception error decimal overflow has occurred during mul

PostPosted: Wed Nov 14, 2018 7:05 pm
by expat
What is the EXACT error message issued, what about any SQL return codes shown.
Psychic day was Monday this week.

Re: exception error decimal overflow has occurred during mul

PostPosted: Tue Dec 11, 2018 6:51 pm
by rakeshsneha1212
expat wrote:What is the EXACT error message issued, what about any SQL return codes shown.
Psychic day was Monday this week.


Sorry for the delay in reply,

Below is the error message

DSNT404I SQLCODE = 802, WARNING:  EXCEPTION ERROR DECIMAL OVERFLOW HAS        
         OCCURRED DURING MULTIPLICATION OPERATION ON DECIMAL DATA, POSITION  *N
DSNT418I SQLSTATE   = 01519 SQLSTATE RETURN CODE



Thanks
Rakesh