ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Strange problem while type casting!

Post new topic  Reply to topic
 Strange problem while type casting! « View previous topic :: View next topic » 
Author Message
cronydude
PostPosted: Thu Jan 24, 2002 5:20 am    Post subject: Reply with quote

Voyager

Joined: 11 Nov 2001
Posts: 85
Location: US

hi,
I have MQSI v2.0.1 on WIN NT.
I am getting values from database n populating xml template.i have a field which is of DOUBLE data type in database(DB2).this value is being retreived into XML file which looks like,

<Test><Datax>1.05E+3</Datax></Test>

i am trying to type cast this to decimal equivalent(1050) with the following ESQL script :

CAST((CAST(InputBody.Test.Datax AS FLOAT)) AS DECIMAL)

It worked most times but failed few a times giving the following error in the event viewer:

" Error casting character string '1.05' to decimal; maximum decimal precision is 31 digits.

Error casting a value from FLOAT to DECIMAL.An error occurred when casting a value of data type FLOAT to a value of data type DECIMAL."

I have even tried casting it directly to DECIMAL with ESQL

CAST(InputBody.Test.Datax AS DECIMAL)

which has also failed.

Could anybody there help please!

regards,
crony



[ This Message was edited by: cronydude on 2002-01-24 06:59 ]

[ This Message was edited by: cronydude on 2002-01-24 07:13 ]
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Strange problem while type casting!
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.