HP3000-L Archives

June 2004, Week 4

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:
Lars Appel <[log in to unmask]>
Reply To:
Lars Appel <[log in to unmask]>
Date:
Wed, 23 Jun 2004 12:09:42 +0200
Content-Type:
text/plain
Parts/Attachments:
text/plain (36 lines)
Jim,

coming late to the party, I still want to point out
an alternate solution for the two issues at hand, just
in case someone else needs it without COBOL coding:

For the issue of trailing blanks, you might use the
/bin/toyte utility, which has an option to convert to
bytestream format *and* trim trailing blanks...

  :xeq /bin/tobyte "-at MYFILE OUTFILE1"

The resulting bytestream file, however, will not have
CR+LF as line delimiters as common on Windows. It will
only have LF as common in POSIX land.

If you use FTP transfer in ASCII mode, the ftp program
should take care of the LF to CR+LF translation. If you
use FTP transfer in BINARY mode, you would need to take
care of that yourself, for example with /bin/awk...

  :xeq /bin/awk " '{print $0 ""\r""}' OUTFILE1 > OUTFILE2 "

Another option would be transfer with smbclient, if the
target PC is not even running an FTP server, but only
shares a directory for network drive mapping. In smbclient
there is an option for CR/LF translation...

  :xeq /usr/local/samba/bin/smbclient &
  : "//myPC/share myPass -c 'translate; put OUTFILE1 pcfile.txt'"

Regards, Lars.

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

ATOM RSS1 RSS2