Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Need to copy COMP-3 variable to VB file.

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

New User


Joined: 21 Dec 2005
Posts: 19

PostPosted: Sat Jun 14, 2008 1:09 am    Post subject: Need to copy COMP-3 variable to VB file.
Reply with quote

I have a COMP-3 variable satrting in an input file(VB) from position 132.
The variable is S9(13) COMP-3.

I need to copy this to an output file (VB) so that I can see the number.

Please help me out with this.
Back to top
View user's profile Send private message

Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Sat Jun 14, 2008 1:41 am    Post subject:
Reply with quote

What do you want in the output file, just the ZD version of the comp-3 field or additional data? What about the sign of the comp-3 field? What is the lrecl of the input and output records.
Back to top
View user's profile Send private message
aditya_gorti

New User


Joined: 21 Dec 2005
Posts: 19

PostPosted: Sat Jun 14, 2008 1:49 am    Post subject:
Reply with quote

I just need the ZD version of the comp-3 field.
I do not want the Sign of comp-3
Lrecl of input - 20429 (VB)
Lrecl of output - 16 (12 + 4-VB)
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10375
Location: italy

PostPosted: Sat Jun 14, 2008 2:30 am    Post subject: Reply to: Need to copy COMP-3 variable to VB file.
Reply with quote

for what reason You want to complicate Your life...
since every record is of the same length, there is no reason to have a varialble length record format...
just wondering
Back to top
View user's profile Send private message
Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Sat Jun 14, 2008 3:23 am    Post subject:
Reply with quote

The following DFSORT JCL will give you the desired results

Code:

//STEP0100 EXEC PGM=ICEMAN                 
//SYSOUT   DD SYSOUT=*                     
//SORTIN   DD DSN=your input vb file,disp=shr
//SORTOUT  DD SYSOUT=*                     
//SYSIN    DD *                             
  SORT FIELDS=COPY                         
  OUTFIL BUILD=(1,4,132,7,PD,M11,LENGTH=12)
/*
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 Moving a COMP-3 Variable to a Numeric... ajayachander COBOL Programming 2 Thu Dec 14, 2017 5:46 pm
No new posts ISSUE IN copying Sequential file reco... thesumitk JCL & VSAM 2 Wed Dec 13, 2017 3:07 pm
No new posts File Tailoring -- Temporary dataset i... samzee71 CLIST & REXX 3 Fri Dec 01, 2017 3:12 am
No new posts Rexx - File tailoring samzee71 CLIST & REXX 10 Thu Nov 30, 2017 10:47 pm
No new posts Moving a PS file as body of a mail! Vignesh Sid JCL & VSAM 4 Tue Nov 21, 2017 9:23 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us