IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

To Convert numeric to PD using Syncsort


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
amdparsn

New User


Joined: 09 Feb 2009
Posts: 8
Location: Chennai

PostPosted: Mon Jan 09, 2012 7:58 pm
Reply with quote

Hi,
Following is my input file where the first 16 numeric data and then 17 to 30 has to be converted to PD.

Please suggest.

Code:
00000000000010000100100001                             5401DK 2080000000ACT71
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Mon Jan 09, 2012 8:36 pm
Reply with quote

And what would you like your output to look like, since the PD are shorter...
Back to top
View user's profile Send private message
amdparsn

New User


Joined: 09 Feb 2009
Posts: 8
Location: Chennai

PostPosted: Mon Jan 09, 2012 8:47 pm
Reply with quote

Of course my o/p has to be shortened , and am going to use this o/p file for loading a table.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Mon Jan 09, 2012 9:31 pm
Reply with quote

Hello,

Rather than the silly "Of course" reply, it would be more productive to answer Bill's question. . .

You have shown the input. Now show the output (in hex using the Code tag).
Back to top
View user's profile Send private message
jerryte

Active User


Joined: 29 Oct 2010
Posts: 202
Location: Toronto, ON, Canada

PostPosted: Tue Jan 10, 2012 3:44 am
Reply with quote

amdparsn wrote:
Hi,
Following is my input file where the first 16 numeric data and then 17 to 30 has to be converted to PD.

Please suggest.


I suggest to use a SORT. Below is sample control statement to convert the first field.
Code:
SORT FIELDS=COPY                     
OUTREC BUILD=(1,16,ZD,TO=PD,LENGTH=8)

The LENGTH= subparm is optional. You can leave it out.
Back to top
View user's profile Send private message
amdparsn

New User


Joined: 09 Feb 2009
Posts: 8
Location: Chennai

PostPosted: Wed Jan 11, 2012 12:42 pm
Reply with quote

Hi There thanks for the code.... I've got the o/p as expected.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts Compare only first records of the fil... SYNCSORT 7
No new posts Need to convert date format DFSORT/ICETOOL 20
No new posts Keep leading zero(s) after convert fl... SYNCSORT 7
No new posts Convert single row multi cols to sing... DFSORT/ICETOOL 6
No new posts convert file from VB to FB and use tr... DFSORT/ICETOOL 8
Search our Forums:

Back to Top