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
 

 

If anybody knows SELCOPY

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

New User


Joined: 19 Feb 2005
Posts: 27
Location: hyderabad-ap-india

PostPosted: Thu Apr 27, 2006 5:20 pm    Post subject: If anybody knows SELCOPY
Reply with quote

If anybody knows SELCOPY,
can you pls help me..
My problem is:-
I have an input file (flat file) of length 80 bytes -FB.
The file cosists of 6 fields. One of the filed is 'Amount' & starts from 11 th position of the input file. Now I have to read this file, change the amount field ( for all the records) by multiplying with 26 and I need to write all these records to a new output file..

Can anyone tell me how to do this? Your immediate and qucik answer is highly appreciated as I need to deliver this tomorrow.

Thanks and Regartds,
Saidarao.
Back to top
View user's profile Send private message

kanda3

New User


Joined: 03 Sep 2005
Posts: 1

PostPosted: Wed May 03, 2006 4:06 pm    Post subject: Re: Selcopy
Reply with quote

Hi,
Try the following:
READ INFILE LRECL 80 BLKSIZE 800
MULT 3 AT 1 BY 2
WRITE OUTFIL BLKSIZE=800


Where MULT 3 AT 1 By 2 means, Amount field is 3bytes long and is located at pos 1 which is multiplied by 2.

Amount field must be in packed decimal.
Back to top
View user's profile Send private message
saidharrao
Warnings : 1

New User


Joined: 19 Feb 2005
Posts: 27
Location: hyderabad-ap-india

PostPosted: Tue May 16, 2006 2:59 pm    Post subject:
Reply with quote

Thank you Kanda,
I have just seen your mail. I kept on watching till 3 days from the day I posted. I learned myself and did the same as it was an urgent task and nobody has replied. It went on live and working fine.

Now my new problem is to compare twoo files and merge them if matches..I have to do this using selcopy and both the files are flat files..


Cheers,
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 Selcopy error ashok_uddaraju All Other Mainframe Topics 1 Fri May 27, 2016 11:46 pm
No new posts Problem with SELCOPY swapnil781 All Other Mainframe Topics 9 Mon Sep 30, 2013 4:56 pm
No new posts Update IMS DB using SELCOPY senthamizh All Other Mainframe Topics 3 Tue Oct 30, 2012 3:46 pm
No new posts Repeat read a file from starting afte... Bill Woodger All Other Mainframe Topics 7 Sun Jun 19, 2011 11:52 am
No new posts Selcopy -how to increase the LRECL of... dick scherrer JCL & VSAM 13 Fri Jul 02, 2010 4:50 pm


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