HP3000-L Archives

September 2008, Week 3

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Denys Beauchemin <[log in to unmask]>
Reply To:
Denys Beauchemin <[log in to unmask]>
Date:
Wed, 17 Sep 2008 07:45:02 -0500
Content-Type:
text/plain
Parts/Attachments:
text/plain (82 lines)
This is far different than what the original message led me to believe, so
I'm glad you cleared up the information.

Variable length files in MPE are somewhat special in that they require the
actual length of the record to precede the record itself.  Since your file
does not have that counter when it hits the COBOL program, you get what you
get.

So what you need to do is to create either a true MPE variable length file,
or better yet, a fixed length file.  I suggest you go for the latter.

This file can be created on the PC using a small program that you can write
or using an editor such as UE to pad each record, but if you have many
records, this will become painful and tedious very quickly, though it could
be used to test a few records for your COBOL program.

Another way would be to bypass Minisoft entirely by using FTP to load the
file directly to the HP3000.  This is a much better solution as Minisoft
will not get in the way.


Denys...
-----Original Message-----
From: HP-3000 Systems Discussion [mailto:[log in to unmask]] On Behalf
Of Tony Girgenti
Sent: Wednesday, September 17, 2008 7:25 AM
To: [log in to unmask]
Subject: Re: [HP3000-L] Upload variable length records ASCII file

I did not see this in the postings, so i am posting it again.

Hello Roy.

We receive a csv ASCII file from a bank onto a Windows XP computer.  The 
records in the file are of varying length.  The fields in the file are all
separated 
by a comma.  At the end of each record is a CR/LF.  However, if one of the 
fields in a record is smaller than the same field in another record, that
causes 
the CR/LF in the record to be in a location(column) that is different than
other 
records.  Consequently, the records in the file from the bank are of varying

lengths.

Since we are using Minisoft WS92 as a terminal emulation program to log on
to 
the HP3000, we are also using Minisoft to upload the bank's csv ASCII
variable 
length record file to the HP.  In the upload to the HP, there is no option
in 
Minisoft to specify that, the file being uploaded to the HP, should be
created 
on the HP as a variable length file.

Once the file is uploaded from the PC to the HP, I have an HP COBOL II 
program that i want to open the file with and read it sequentially from 
beginning to end.  After reading the first record, which is 256 bytes in
length, 
the data in the first 256 bytes, contains all of the first record plus some
of the 
second record.  The second record read contains the second part of the 
second record and part of the third record.  I guess what it is doing is
giving 
me 256 bytes at a time, but the records are really different lengths.

Please let me know if you need anything else.

Thanks for all of your help.

Tony

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
No virus found in this incoming message.
Checked by AVG - http://www.avg.com 
Version: 8.0.169 / Virus Database: 270.6.21/1674 - Release Date: 9/16/2008
8:15 AM

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

ATOM RSS1 RSS2