Author Topic: Unable to read from offset 0 for length 26118 from the file  (Read 3905 times)

DDP021

  • Sr. Member
  • ****
  • Posts: 343
    • View Profile
I'm receiving the above error when attempting to load a txt file...The setup is using ACIF indexer..What's interesting is, I can load the initial file successfully..The error started appearing AFTER the added a new line at the top of the file...To define the setups, I'm using the REPORT WIZARD..I run both file types through the wizard..They added the new line in order to pull a specific date..Everything points to how this new line was added..I initially thought that maybe the line that was added didn't have a NEW LINE character at the end X'0A' since the error indicated offset 0 which would indicate the first line on the file...When I run both files through the wizard I just specify DATA CONVERSION=NO, File Format=STREAM, CC=No and the CODE PAGE=1252 (German Data)..I leave the NEW LINE box blank...After running through the wizard and check the APPLICATION, it's specifying RECFM=Stream and Delimiter is 0A.  The user indicated his new line is ending in 0A...I don't have any type of editor myself...He is emailing both files to us and we save them to our desktop..When opening them, they open in NOTEPAD...I have no way of determining how this new line is formattted...Anyone have an ideas what could be different with this new line that would cause the error in the subject line?...

jeffs42885

  • Guest
Re: Unable to read from offset 0 for length 26118 from the file
« Reply #1 on: May 29, 2013, 11:17:37 AM »
On an AIX system, I would usually vi the file and look for any ^M.. this has happened many times to me and I have had to go back to the source system and tell them to resend.

rick

  • Guest
Re: Unable to read from offset 0 for length 26118 from the file
« Reply #2 on: June 04, 2013, 12:07:18 AM »
check if file has 26118 bytes

DDP021

  • Sr. Member
  • ****
  • Posts: 343
    • View Profile
Re: Unable to read from offset 0 for length 26118 from the file
« Reply #3 on: June 05, 2013, 07:02:22 AM »
We found the issue...After the user had edited the file adding  the new line at the top, for some reason it removed the x'0A' at the very end of the file...After putting that back in the file (using PSPAD editor), we were then able to successfully load the data.  Thanks to all for all their input!