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
 

 

To add four spaces at the end of each record in a VB file

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
Vinay N.G

New User


Joined: 15 Sep 2008
Posts: 36
Location: Bangalore

PostPosted: Wed Jul 01, 2009 4:53 pm    Post subject: To add four spaces at the end of each record in a VB file
Reply with quote

Here i have a requirement that i would like to add only 4 spaces at the end of each record for variable record length file using sort .

If the record in the file is equal to LRECL of that file then it should not add spaces.

4 Spaces to be added at the end of every record and then after padding 4 spacess it should have blanks until the LRECL.
Back to top
View user's profile Send private message

Bill Dennis

Active Member


Joined: 17 Aug 2007
Posts: 562
Location: Iowa, USA

PostPosted: Wed Jul 01, 2009 7:22 pm    Post subject: Re: To add four spaces at the end of each record in a VB fil
Reply with quote

Vinay N.G wrote:
If the record in the file is equal to LRECL of that file then it should not add spaces.
Are you aware that each variable length record has a 4 byte RDW in the front? Therefore, the record size is probably equal to the LRECL (counting the extra 4 bytes).

You don't see the RDW prefix when viewing in ISPF so the record may appear to be short 4 bytes.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8120
Location: East Dubuque, Illinois, USA

PostPosted: Wed Jul 01, 2009 7:28 pm    Post subject:
Reply with quote

Quote:
4 Spaces to be added at the end of every record and then after padding 4 spacess it should have blanks until the LRECL.
Could you please explain what this means? Let us assume LRECL=604 so maximum record size is 600 bytes. The record is 307 bytes long. According to what you said, the last 293 bytes all need to be set to spaces (in case you are not aware, "blanks" is another term for "spaces" and both refer to hex '40' character of EBCDIC).
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Wed Jul 01, 2009 7:35 pm    Post subject:
Reply with quote

Just wondering the reason behind adding spaces / blanks at the end of a VB record.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8120
Location: East Dubuque, Illinois, USA

PostPosted: Wed Jul 01, 2009 7:41 pm    Post subject:
Reply with quote

expat, maybe somebody wants to test the FTPTRAILINGBLANKS option of TCPIP?
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Thu Jul 02, 2009 12:52 pm    Post subject:
Reply with quote

/Bad-Day-Start on

Robert Sample wrote:
expat, maybe somebody wants to test the FTPTRAILINGBLANKS option of TCPIP?
This thought seems to be so distant from this thread per se. The way original question is posed it's hard to believe some one could think this intelligent.

/About off..not sure
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8120
Location: East Dubuque, Illinois, USA

PostPosted: Thu Jul 02, 2009 4:47 pm    Post subject:
Reply with quote

Quote:
The way original question is posed it's hard to believe some one could think this intelligent.
Anuj, methinks thou doth presume too much. icon_smile.gif Intelligent? No. Make-work? Possible. Reserving space for an upcoming change? Maybe.
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Split file based on comparsion to 2 f... Div Grad DFSORT/ICETOOL 0 Thu Jul 27, 2017 9:16 pm
No new posts Read two inputs and write into output... murali.andaluri DFSORT/ICETOOL 6 Wed Jul 26, 2017 7:35 pm
No new posts Extra character appears in file when ... Balu5491 All Other Mainframe Topics 1 Wed Jul 26, 2017 2:39 pm
No new posts SSH - known_hosts file configuration vasanthz All Other Mainframe Topics 2 Wed Jul 26, 2017 2:10 am
This topic is locked: you cannot edit posts or make replies. Fetching data from BAI File arunsoods JCL & VSAM 1 Wed Jul 19, 2017 4:28 pm


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