|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Decimal cast is not creating leading zeros in WBIMB |
« View previous topic :: View next topic » |
Author |
Message
|
Antony |
Posted: Tue Apr 27, 2004 11:23 pm Post subject: Decimal cast is not creating leading zeros in WBIMB |
|
|
Newbie
Joined: 22 Apr 2004 Posts: 5 Location: Melbourne, Australia
|
Hi all,
I have done some experimenting and it seems like decimal to decimal casts have different behavior under MQSI 2.1 than under WBIMB 5.0.
I have compared the following systems;
-WBIMB 5 (with rules & formatter extention) with CSD 02 (03 not yet availble for RF extention) on win2k.
-MQSI 2.1 on AIX 5.2
It looks like that in a WBIMB 5 ESQL, a decmial cast with a precision value, which should return leading zeros, has the leading zeros trimed. The example below shows the WBIMB is not acting as expected.
Given the following input message in the XML domain:
Code: |
<body>
<comp>1001</comp>
</body>
|
which passes through a compute node with the following code;
Code: |
SET OutputRoot = InputRoot;
declare tt decimal;
set tt = "InputRoot"."XML"."body"."comp";
set tt = cast(tt as decimal(12,4));
set "OutputRoot"."XML"."body"."ant" = tt;
set "OutputRoot"."XML"."body"."antc" = cast ( cast(tt as decimal(12,4)) as
character);
|
The output result on WBIMB 5 is;
Code: |
<body>
<comp>1001</comp>
<ant>1001.0000</ant>
<antc>1001.0000</antc>
</body>
|
The output result on MQSI 2.1 is;
Code: |
<body>
<comp>1001</comp>
<ant>00001001.0000</ant>
<antc>00001001.0000</antc>
</body>
|
Any thoughts?
Thanks,
Antony |
|
Back to top |
|
 |
Antony |
Posted: Sun May 02, 2004 8:53 pm Post subject: |
|
|
Newbie
Joined: 22 Apr 2004 Posts: 5 Location: Melbourne, Australia
|
IBM support has told me that a change was made in the decimal cast processing in WBIMB 5, so it no longer creates leading zeros.
Antony |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
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
|
|
|
|