On Mon, May 15, 2023 at 06:54:40PM +0000, 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.
Let's see if I understand the problem, here's a summary I see: You tried 3 transfer mechanisms for the z/OS to your windows machine (I'm assuming it's from z/OS since this is the mainframe list). 1. FTP -> what options did you use? 2. Terse & XMIT and then ? how did it get to windows? What do you have on windows which can process this combination of format? 3. IND$FILE which you decided isn't really a candidate due to file sizes. On the windows machine you are trying to read the resulting file with python. Which python: python 2 or python 3? Did you specify binary mode on the python open call? The raw VB & VBS files sound relatively easy to read with python by reading in binary mode and using the BDW/RDW information to separate the records. I'm not sure how you would deal with undoing the XMIT and Terse on windows once you got an intact file there. ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN