Thank you, Michael,
I used WWUNTERSE for my terse file. I am able to get RDW & BDW and also able to
read data after proper conversion. Problem is when I read file for each record
(using loop), I get different record lengths for each record, in range of
single digit to thousands. Seems it adds "new line" randomly in file. I can use
record length field in RDW to read each records but this random "new line"
breaks my loop.
I also tried to STRIP (remove additional space from end of record) these
records to remove "new line" character and converted entire file as one single
record. Now I get only one record and can use record length field in RDW to
split file. But then this STRIP option removes some record information as well
along with "new line" character. Hence it affects my real record length.
Thanks,
Prashant
-----Original Message-----
From: IBM Mainframe Discussion List <[email protected]> On Behalf Of
Michael Oujesky
Sent: Tuesday, May 16, 2023 4:54 AM
To: [email protected]
Subject: [EXTERNAL] Re: VBS file read in windows - end of record issue
Depend on what you need to do and there at least two levels to be addressed:
* How variable length records appear on Windows
* How to deal with SDW (spanned long record segments If you want both BDW
and RDW/SDW present on Windows at least two approaches:
* TERSE the file, binary transfer to windows, WWUNTERSE from Watson &
Walker) on windows (-V option removes BDW)
* FTP binary transfer from z/OS to Windows using //DD: and JCL to force
RDCFM=U Regular FTP binary transfer with "SITE RDW" will give you the file with
just RDW/SDW (BDW is stripped off). Without the "SITE RDW", you just get the
data with no indication of where the record ends).
Then there is the issue of how to re-combine the segments into the full record
length.
Does that help any?
Michael
At 01:54 PM 5/15/2023, Prashant Joshi wrote:
>I am trying to read VB & VBS binary file in windows using python. I
>tried FTPing file directly, then using Terse and then XMIT but every
>time when I read the file in windows, I get random new line (CR/LF)
>inserted in record. I am not able to read complete record.
>
>For some files, when I transfer using IND$FILE (option 6) using Binary
>and CRLF option checked, I gets record properly. But it does not work
>for every file. And due to different file sizes, IND$FILE may not be
>option for me.
>
>
>
>Need your help to find, what am I missing?
>
>
>Thanks,
>Prashant
>
>----------------------------------------------------------------------
>For IBM-MAIN subscribe / signoff / archive access instructions, send
>email to [email protected] with the message: INFO IBM-MAIN
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions, send email to
[email protected] with the message: INFO IBM-MAIN
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN