Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Convert invalid PD data to valid one

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
nitin_agr

New User


Joined: 06 Sep 2005
Posts: 28
Location: Minneapolis US

PostPosted: Sat Dec 09, 2006 8:34 pm    Post subject: Convert invalid PD data to valid one
Reply with quote

Hi Friends;
I am facing a small problem, please have a look and help me for the same.

I have an input dataset of 6 bytes, with a field typer packed decimal 6 bytes, cobol copybook data type PIC S9(11) COMP-3

In my input dataset, it has value as X'000000000064', I want to convert the value to edit clause so that I can view 100 instead of hexadecimal value. Also, I dont want the record length to be changed after formatting.

I tried many ways to convert it but couldn't suceeded.
Please suggest.
Back to top
View user's profile Send private message

Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Sat Dec 09, 2006 9:50 pm    Post subject:
Reply with quote

X'000000000064' is NOT a PD value and not PIC S9(11) COMP-3. It's actually a 6-byte BI value of 100. So you can convert it using:

p,6,BI,M10,LENGTH=6

or whatever edit mask you like.

Note that a 6-byte BI value can result in more than 6 digits, but I used LENGTH=6 since you said you don't want to change the length. So this could result in truncation. LENGTH=15 would prevent truncation.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Data replication from multiple Db2 ta... kishpra DB2 5 Mon Mar 27, 2017 9:58 pm
No new posts Export flat file data into excel sheet murali.andaluri DFSORT/ICETOOL 2 Mon Mar 20, 2017 5:39 pm
No new posts Append data from two files into a sin... Praveen04 DFSORT/ICETOOL 5 Thu Mar 16, 2017 7:29 pm
No new posts SPUFI -- Joining 3 tables – data in... Sysaron DB2 2 Wed Mar 08, 2017 4:18 am
No new posts Overriding PS data in rexx Shaheen Shaik CLIST & REXX 8 Fri Mar 03, 2017 5:08 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us