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
 

 

Using File Mangaer in JCL to truncate chars above 50

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IBM Tools
View previous topic :: :: View next topic  
Author Message
kalyanp_80

New User


Joined: 03 Feb 2006
Posts: 41
Location: Hyderabad

PostPosted: Fri Feb 23, 2007 10:23 am    Post subject: Using File Mangaer in JCL to truncate chars above 50
Reply with quote

Hi,

I am new to File Manager. But I have a requirement whcih asks me to use File Manager in JCL step.

My requirement is to create a FileManager batch job step to blank characters > 50 for column starting in 10 location and size is 70 characters. Suppose for a record if this column has 50 chars I should not touch this record, but if a record has anything greater than 50 I should delete characters after 50.

Thanks in advance!

Amith Patalay
Back to top
View user's profile Send private message

guptae

Moderator


Joined: 14 Oct 2005
Posts: 1187
Location: Bangalore,India

PostPosted: Fri Feb 23, 2007 11:30 am    Post subject:
Reply with quote

Hi There,

Would u please provide example of i/p & o/p?
Back to top
View user's profile Send private message
kalyanp_80

New User


Joined: 03 Feb 2006
Posts: 41
Location: Hyderabad

PostPosted: Fri Feb 23, 2007 11:42 am    Post subject: Re: Using File Mangaer in JCL to truncate chars above 50
Reply with quote

Ekta,

My input record is lil big :-). I will try to illustrate my requirement with simple example:

Assume my input file is FB with RECL = 10 and it has following input:
AAAAAAAAAA
BBBBB
CCCCCCC
DDD

Now my requiremnt is to copy only 5 positions of input file to output file. It should truncate all the data above > 5. Out put will look lie below:

AAAAA
BBBBB
CCCCC
DDD

Thanks
Amith
Back to top
View user's profile Send private message
abyss232006

New User


Joined: 31 Jan 2007
Posts: 3
Location: Kokata

PostPosted: Tue May 15, 2007 4:41 pm    Post subject:
Reply with quote

Hi Amith,
You can do it using icetool or DFSORT and 'OUTREC' formatting
Please find the below example

//S1 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN1 DD *
AAAAAAAAAAAAAAAAAAAAAAA
BBBBBBBBBBBB
CCCCCCCCCCCCCCCCCCCCCCCCC
//OUT DD SYSOUT=*
//TOOLIN DD *
*REFORMAT THE IN1 DATA SET SO IT CAN BE SPLICED
COPY FROM(IN1) TO(OUT) USING(CTL1)
/*
//CTL1CNTL DD *
*USE OUTFIL OUTREC TO REMOVE THE SEQUENCE NUMBER
OUTFIL FNAMES=OUT,OUTREC=(1,05)
/*
[/code]

In case of DFsort you can use the control statement accordingly
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 -> IBM Tools All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Copy RECFM =VB TO FB file with RECL =... sahil41352 DFSORT/ICETOOL 3 Wed Dec 28, 2016 11:29 pm
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm
No new posts File Aid to File Manager conversion murali3955 IBM Tools 4 Thu Nov 24, 2016 3:41 pm
No new posts How to convert the VBM file to VB or... Sulabh Agrawal JCL & VSAM 4 Fri Nov 18, 2016 1:04 pm
No new posts CICS Roll back partially - Need to re... dwijadas CICS 4 Wed Nov 16, 2016 4:30 pm


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