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 IndexWebSphere Message Broker (ACE) SupportPacked decimal Comp-3 values not writing correctly

Post new topicReply to topic
Packed decimal Comp-3 values not writing correctly View previous topic :: View next topic
Author Message
Angshuman
PostPosted: Thu May 21, 2009 10:30 pm Post subject: Packed decimal Comp-3 values not writing correctly Reply with quote

Apprentice

Joined: 30 Apr 2009
Posts: 29

Hi Guys,

I am parsing data i.e; packed decimal Comp-3 ... I have created a messge tree to read the data but while writing the data it is storing some junk values. Destination is a mainframe system, so i have used encoding 530. Just to show the actual data and the data my message flow is generating :


Actual Data : Y US 2

My Data : Y! US)2

If you notice there is an special character ) in the data which is actually suppose to be space.

The mainframe system is not able to read the message i am sending.

Can anyone help.. Thanks in advance
Back to top
View user's profile Send private message
Vitor
PostPosted: Thu May 21, 2009 10:59 pm Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

What version of WMB? Running on what OS (and platform, as encoding is clearly an issue here). Is everything on Z/Linux or are you going "out and back"?

To repeat some good advice often given, have you taken a user trace to see what's actually happening when the output tree is built? How is your message set defined? Was it built by hand, or imported from a copybook? What is the source of the data, and how is that defined / encoded?

More information, more advice.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
Angshuman
PostPosted: Fri May 22, 2009 2:35 am Post subject: Reply with quote

Apprentice

Joined: 30 Apr 2009
Posts: 29

Thanks for the quick response.

WMB Version = 6.1 running on windows OS.

But the target system is z/OS. I have changed the CCSID and Encoding accordingly.

Message set is a CWF that is generated out of a copybook.

Surprisingly, i get the correct output when the values for the packed decimal is 1 or 0. For eg 110.00.
But when I give the values other than 1 and 0, i.e, from 2-9, it is giving junk value in the output.

Just curious to know whether packed decimal conversion is limited to only binary.
Back to top
View user's profile Send private message
Vitor
PostPosted: Fri May 22, 2009 2:42 am Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

Angshuman wrote:
Just curious to know whether packed decimal conversion is limited to only binary.


No it's not.

Angshuman wrote:
But the target system is z/OS. I have changed the CCSID and Encoding accordingly.


Where? Broker, queue manager, input message or output message? These values should always reflect the values actually used in the message.

Angshuman wrote:
Message set is a CWF that is generated out of a copybook.


What's the picture of the clause(s) giving trouble? How is the field actually represented in the message set? What did the trace show?
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
Angshuman
PostPosted: Fri May 22, 2009 3:19 am Post subject: Reply with quote

Apprentice

Joined: 30 Apr 2009
Posts: 29

I have changed the CCSID and Encoding at Broker level.

I can see the properties getting changed when i run the flow in debug mode.

Picture clause of the 2 COMP fields

05 ADTL-HC-PCT PIC S9(1)V9(2) COMP-3.
05 DISC-PCT PIC S9(3)V9(2) COMP-3.

In the message set I have given the type of the 2 fields as PACKED DECIMAL with length 2 and 3 respectively.
Back to top
View user's profile Send private message
Vitor
PostPosted: Fri May 22, 2009 3:45 am Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

Angshuman wrote:
I can see the properties getting changed when i run the flow in debug mode.


Trace not debug. It has more detail.

Angshuman wrote:
In the message set I have given the type of the 2 fields as PACKED DECIMAL with length 2 and 3 respectively.


I thought you said you generated the message set from a copybook? Why are you setting the values manually?

And why the change at broker level? What happens if the broker runs native and the message details are changed?
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Fri May 22, 2009 10:14 am Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Angshuman wrote:
I have changed the CCSID and Encoding at Broker level.

I can see the properties getting changed when i run the flow in debug mode.

Picture clause of the 2 COMP fields

05 ADTL-HC-PCT PIC S9(1)V9(2) COMP-3.
05 DISC-PCT PIC S9(3)V9(2) COMP-3.

In the message set I have given the type of the 2 fields as PACKED DECIMAL with length 2 and 3 respectively.

Describe output message properties and MQMD properties:
message/MQMD format
message/MQMD ccsid
message/MQMD encoding..
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Angshuman
PostPosted: Tue May 26, 2009 9:51 pm Post subject: Reply with quote

Apprentice

Joined: 30 Apr 2009
Posts: 29

Vitor/fjb_saper

Quote:
Describe output message properties and MQMD properties:
message/MQMD format
message/MQMD ccsid
message/MQMD encoding..


Input message is in a File so i am using a file protocol and not MQ. Here are the File properties :

MessageFormat CWF1
Encoding 530
CodedCharSetId 819


Quote:
I thought you said you generated the message set from a copybook? Why are you setting the values manually?


I am not changing the message set. I have imported it from the copybook.


I have developed a reverse flow just to decode the COMP-3 values and i am getting correct result. Even in RFHUTIL i can see the output file generated is correct.
Its just when that output file is fed to mainframe, it is giving some junk values.
I believe its the encoding issue or problem with ASCII to EBCDIC conversion because in windows system the value seems to be correct.

Can anybody tell me what is the encoding mechanism of z/OS system and what is the encoding code as I am using 530.

Thanks in advance.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Wed May 27, 2009 5:07 pm Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

You should be using something like encoding 847 and ccsid 37 or 500... on the output
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Angshuman
PostPosted: Thu May 28, 2009 1:32 am Post subject: Reply with quote

Apprentice

Joined: 30 Apr 2009
Posts: 29

Thank you fjb_saper...
It worked
Back to top
View user's profile Send private message
Display posts from previous:
Post new topicReply to topic Page 1 of 1

MQSeries.net Forum IndexWebSphere Message Broker (ACE) SupportPacked decimal Comp-3 values not writing correctly
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.