View previous topic :: View next topic
|
Author |
Message |
shaktiprasad
New User
Joined: 20 Aug 2006 Posts: 34 Location: chennai
|
|
|
|
Hi ,
I want to copy a vsam file(which has same avg record length and max record length) to a vb sequential file.
This vsam file has been copied from another vb file.I am doing some processing in the vsam and then want to copy it to another vb file.
so while copying trailing spaces are being copied to the vb file .
But don't want those trailing spaces.
How to do this while copying from vsam to vb file? |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8796 Location: Welsh Wales
|
|
|
|
How do you verify that there are trailing spaces.
What do you use to copy the files.
Please show us examples. |
|
Back to top |
|
|
shaktiprasad
New User
Joined: 20 Aug 2006 Posts: 34 Location: chennai
|
|
|
|
I am able to see the trailing spaces when I put HEX ON.it's showing 4040 while normal vb file it's showing nothing. |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8796 Location: Welsh Wales
|
|
|
|
In EDIt, VIEW or BROWSE ? |
|
Back to top |
|
|
shaktiprasad
New User
Joined: 20 Aug 2006 Posts: 34 Location: chennai
|
|
|
|
expat wrote: |
In EDIt, VIEW or BROWSE ? |
In BROWSE. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19243 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
I am doing some processing in the vsam and then want to copy it to another vb file.
so while copying trailing spaces are being copied to the vb file . |
How did you create the copy? |
|
Back to top |
|
|
shaktiprasad
New User
Joined: 20 Aug 2006 Posts: 34 Location: chennai
|
|
|
|
dick scherrer wrote: |
Hello,
Quote: |
I am doing some processing in the vsam and then want to copy it to another vb file.
so while copying trailing spaces are being copied to the vb file . |
How did you create the copy? |
1st I copied from vb to vsam using sort with VTOF option in control card(when i am not using VTOF the job is abending showing in sysout that no RDW specified).
Then I am copying from vsam to another vb file using sort fields=copy. |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8796 Location: Welsh Wales
|
|
|
|
VTOF converts the file from VB to FB. That could go a little way to explaining why you have the spaces at the end. |
|
Back to top |
|
|
Arun Raj
Moderator
Joined: 17 Oct 2006 Posts: 2481 Location: @my desk
|
|
|
|
shaktiprasad,
Quote: |
1st I copied from vb to vsam using sort with VTOF option in control card |
You said you copied from VB to VSAM using VTOF; but VTOF as mentioned above is to convert from Variable To Fixed.
Can you tell what kind of "processing" you're doing here.
You can give a try adding this to your card to copy the file back to VB.
Code: |
OUTFIL FTOV,VLTRIM=C' ' |
|
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8796 Location: Welsh Wales
|
|
|
|
And post some code and information regarding the VSAM and PS files.
LRECL, RECFM etc. etc. |
|
Back to top |
|
|
shaktiprasad
New User
Joined: 20 Aug 2006 Posts: 34 Location: chennai
|
|
|
|
what is this VLTRIM=C' ' exactly do?
hi my vb file has lrecl of 600 and vsam file has lrecl of 596. |
|
Back to top |
|
|
Arun Raj
Moderator
Joined: 17 Oct 2006 Posts: 2481 Location: @my desk
|
|
|
|
SyncSort for z/OS 1.2 Manual wrote: |
VLTRIM Parameter (Optional)
The VLTRIM parameter defines a byte to be deleted from the end of a variable-length record. All prior occurrences of this byte will also be deleted until a byte that is not equal to the trim byte is found. The resulting records are decreased in record length. However, VLTRIM will not delete the first data byte, the ANSI carriage control character, or the Record Descriptor Word (RDW). |
shaktiprasad,
If you're still facing issues, post the requested info before we proceed any further. |
|
Back to top |
|
|
shaktiprasad
New User
Joined: 20 Aug 2006 Posts: 34 Location: chennai
|
|
|
|
Thanks Arun ,it worked. |
|
Back to top |
|
|
Arun Raj
Moderator
Joined: 17 Oct 2006 Posts: 2481 Location: @my desk
|
|
|
|
shaktiprasad wrote: |
Thanks Arun ,it worked. |
You're welcome |
|
Back to top |
|
|
|