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

Copy records from one member to another


IBM Mainframe Forums -> TSO/ISPF
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
jsnair

New User


Joined: 26 Sep 2006
Posts: 38
Location: India

PostPosted: Fri May 23, 2008 3:29 pm
Reply with quote

Hi,

I need to copy 3rd and 4th record from Member1 and paste it after 6th record in Member2. Both these members are in different PDS. Please let me know how can I do this.


Member1

Code:
****** ***************************** Top of Data *******
000001 The first line of data                           
000002 The second line of data                         
000003 The third line of data                           
000004 The fourth line of data                         
000005 The fifth line of data                           
000006 The sixt line of data                           
000007 The 7th line of data                             
000008 The 8th line of data                             
000009 The 9th line of data                             
000010 The 10th line of data                           
****** **************************** Bottom of Data *****


Member2

Code:
****** ***************************** Top of Data *******
000001 The first line of data                           
000002 The second line of data                         
000003 The third line of data                           
000004 The fourth line of data                         
000005 The fifth line of data                           
000006 The sixt line of data                           
000007 The 7th line of data                             
000008 The 8th line of data                             
000009 The 9th line of data                             
000010 The 10th line of data                           
****** **************************** Bottom of Data *****
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Fri May 23, 2008 3:32 pm
Reply with quote

CUT and PASTE

cut data will be saved for the whole TSO session
Back to top
View user's profile Send private message
Aaru

Senior Member


Joined: 03 Jul 2007
Posts: 1287
Location: Chennai, India

PostPosted: Fri May 23, 2008 3:32 pm
Reply with quote

nair,

You can use the Block commands for the same

Open the member 1

- CC and CC and then CUT

open the 2nd member

- A/B (after/before) and then PASTE .
Back to top
View user's profile Send private message
jsnair

New User


Joined: 26 Sep 2006
Posts: 38
Location: India

PostPosted: Fri May 23, 2008 3:39 pm
Reply with quote

Hi enrico and Aaru,

Thanks for the help. It is now working fine. Earlier I was trying with COPY.
Back to top
View user's profile Send private message
satheeshkamal

New User


Joined: 09 Jan 2007
Posts: 28
Location: Chennai

PostPosted: Fri May 23, 2008 3:55 pm
Reply with quote

If the records are not in sequence, for example, if you want the 2nd record and 6th record from member 1 to member 2 in sequence.

Cut the contents into a clipboard

use line command "C" in line 2nd and
Code:
Cut a

a - Clipboard name

Then, use the same command in line 5th and
Code:
Cut a append


Then open member2 and paste it after/before as you wish
Back to top
View user's profile Send private message
jsnair

New User


Joined: 26 Sep 2006
Posts: 38
Location: India

PostPosted: Fri May 23, 2008 4:08 pm
Reply with quote

Hi satheeshkamal,

It was really good. Thanks for your update.
Back to top
View user's profile Send private message
yogeshwar_ade

Active User


Joined: 31 Aug 2006
Posts: 103
Location: INDIA

PostPosted: Fri May 23, 2008 7:09 pm
Reply with quote

satheeshkamal wrote:
If the records are not in sequence, for example, if you want the 2nd record and 6th record from member 1 to member 2 in sequence.

Cut the contents into a clipboard

use line command "C" in line 2nd and
Code:
Cut a

a - Clipboard name

Then, use the same command in line 5th and
Code:
Cut a append


Then open member2 and paste it after/before as you wish



Good Info, Thanks

Yogeshwar
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Thu May 29, 2008 6:25 pm
Reply with quote

Hi Jiji,

The solutions mentioned are probably faster, but you CAN use COPY to do what you want:

On the 6 th line of Member 2 enter an "a", then on the cmd line enter "COPY", then hit enter. On the next panel that appears enter the DSN and member in the space provided {e.g. MY.DSN(MEMBER1)}.

At the bottom of the screen you'll see places to enter the 1st line and last line to copy and the number type. Enter them - Use "R" for the number type.

Member 2
Code:
************************************ Top of Data *******
000001 The first line of data                           
000002 The second line of data                         
000003 The third line of data                           
000004 The fourth line of data                         
000005 The fifth line of data                           
a00006 The sixt line of data                           
000007 The 7th line of data                             
000008 The 8th line of data                             
000009 The 9th line of data                             
000010 The 10th line of data                           
****** **************************** Bottom of Data *****

Member 1:
Code:
****** ***************************** Top of Data *******
000001 The first line of data                           
000002 The second line of data                         
000003 The third line of data                           
000004 The fourth line of data                         
000005 The fifth line of data                           
000006 The sixt line of data                           
000007 The 7th line of data                             
000008 The 8th line of data                             
000009 The 9th line of data                             
000010 The 10th line of data                           
****** **************************** Bottom of Data *****
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 -> TSO/ISPF

 


Similar Topics
Topic Forum Replies
No new posts Compare 2 files and retrive records f... DFSORT/ICETOOL 3
No new posts Compare 2 files(F1 & F2) and writ... JCL & VSAM 8
No new posts Compare only first records of the fil... SYNCSORT 7
No new posts Pulling a fixed number of records fro... DB2 2
No new posts VB to VB copy - Full length reached SYNCSORT 8
Search our Forums:

Back to Top