MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Inserting negative value using OUTREC

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities
View previous topic :: View next topic  
Author Message
vivek1983
Intermediate


Joined: 20 Apr 2006
Posts: 222
Topics: 24

PostPosted: Tue May 08, 2007 6:25 am    Post subject: Inserting negative value using OUTREC Reply with quote

Hi,


I am trying to insert a new field value to a file.
I am doing this using OUTREC statement in the sort card. Find below the scenario:

Input File : AAAABBB
My desired output file: AAAABBB-1

The '-1' field is of S9(09) comp in the referred cobol program.

I have searched this forum but I have not got any idea of how to do that because I have not used much of sort techniques so far.

Please let me know how to accomplish this.

Thanks in advance.
Vivek G
Back to top
View user's profile Send private message
dbzTHEdinosauer
Supermod


Joined: 20 Oct 2006
Posts: 1411
Topics: 26
Location: germany

PostPosted: Tue May 08, 2007 7:02 am    Post subject: Reply with quote

search on outrec - modification; look at the manuals.

this link will give you an idea of which parms and the syntax that you need. then you can code your own sort.

http://www.mvsforums.com/helpboards/viewtopic.php?t=7784&highlight=file1value
_________________
Dick Brenholtz
American living in Varel, Germany
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12366
Topics: 75
Location: San Jose

PostPosted: Tue May 08, 2007 7:07 am    Post subject: Reply with quote

vivek1983,

vivek1983,

try this control card.

Code:

//SYSIN    DD *                   
  SORT FIELDS=COPY                 
  OUTREC FIELDS=(01,07,           
                 -1,TO=FI,LENGTH=4)


Hope this helps...

Cheers

Kolusu
_________________
Kolusu - DFSORT Development Team (IBM)
DFSORT is on the Web at:
www.ibm.com/storage/dfsort

www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities All times are GMT - 5 Hours
Page 1 of 1

 
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


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group