Rocksolid Light

Welcome to RetroBBS

mail  files  register  newsreader  groups  login

Message-ID:  

Hoping to goodness is not theologically sound. - Peanuts


devel / comp.lang.cobol / [OT] IND$FILE Settings for 'Tab-Delimited' ASCII File

SubjectAuthor
* [OT] IND$FILE Settings for 'Tab-Delimited' ASCII Filedocdwarf
`* Re: [OT] IND$FILE Settings for 'Tab-Delimited' ASCII FileDennis Lee Bieber
 `- Re: [OT] IND$FILE Settings for 'Tab-Delimited' ASCII Filedocdwarf

1
[OT] IND$FILE Settings for 'Tab-Delimited' ASCII File

<sgqo5u$2n$1@reader1.panix.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=187&group=comp.lang.cobol#187

  copy link   Newsgroups: comp.lang.cobol
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!panix!.POSTED.panix1.panix.com!not-for-mail
From: docdwarf@panix.com
Newsgroups: comp.lang.cobol
Subject: [OT] IND$FILE Settings for 'Tab-Delimited' ASCII File
Date: Thu, 2 Sep 2021 14:47:26 -0000 (UTC)
Organization: Public Access Networks Corp.
Message-ID: <sgqo5u$2n$1@reader1.panix.com>
Injection-Date: Thu, 2 Sep 2021 14:47:26 -0000 (UTC)
Injection-Info: reader1.panix.com; posting-host="panix1.panix.com:166.84.1.1";
logging-data="87"; mail-complaints-to="abuse@panix.com"
X-Newsreader: trn 4.0-test77 (Sep 1, 2010)
 by: docdwarf@panix.com - Thu, 2 Sep 2021 14:47 UTC

I've got a file that I'm looking to load into a dataset and it's proving
to be a nuisance.

The file is created by Unix-based processes and uses X'25' as a
record-delimiter. It's supposed to wind up as a collection of
160-character records, space-padded as needed.

Starting with clicking the 'Unix File' box on I've tried just about every
combination and permutation of setting, variations, options and flavors
the TSO File tab allows: fixed length, VB, Undefined, None and lengths of
160, 161 and 162 but nothing works; the output winds up as:

FIRST-SHORT-REC(X'25')SECONDREC DATA HERE AS FAR AS IT GOES(X'25')THIRD
REC HERE FOR SOME MORE(X'25)FOURTH RECORD AT THIS POINT (&c)

That kind of 'striping' of records usually happens when the output LRECL
and the input don't match (and that kind of fits in with X'25' delimiters
instead of X'0D0A'.

Is there a setting I'm missing... or is there a quick-and-dirty PC-based
utility that will get it from variable-length tab-delimited format to
LRECL 160 with space-padding?

Thanks much.

DD

Re: [OT] IND$FILE Settings for 'Tab-Delimited' ASCII File

<qvr1jg9l3lc10en767nfj51qavdlc532eu@4ax.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=188&group=comp.lang.cobol#188

  copy link   Newsgroups: comp.lang.cobol
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!buffer2.nntp.dca1.giganews.com!news.giganews.com.POSTED!not-for-mail
NNTP-Posting-Date: Thu, 02 Sep 2021 11:11:39 -0500
From: wlfraed@ix.netcom.com (Dennis Lee Bieber)
Newsgroups: comp.lang.cobol
Subject: Re: [OT] IND$FILE Settings for 'Tab-Delimited' ASCII File
Date: Thu, 02 Sep 2021 12:11:40 -0400
Organization: IISS Elusive Unicorn
Message-ID: <qvr1jg9l3lc10en767nfj51qavdlc532eu@4ax.com>
References: <sgqo5u$2n$1@reader1.panix.com>
User-Agent: ForteAgent/8.00.32.1272
X-No-Archive: yes
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Lines: 56
X-Usenet-Provider: http://www.giganews.com
X-Trace: sv3-3IfdzmTZarqjRyhV8upIm7HsFbXdXouwH7KGssFe1wpdOX/5FoB6PyHeKjA8+qvD+P5fjN9NiGSczwO!LLXemAelmau6wNsBF8CM2HzfLk44ST/sui6mLdL1mw24imDDT4l8K05dwn5aZY5rYFjhLAox
X-Complaints-To: abuse@giganews.com
X-DMCA-Notifications: http://www.giganews.com/info/dmca.html
X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers
X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly
X-Postfilter: 1.3.40
X-Original-Bytes: 3766
 by: Dennis Lee Bieber - Thu, 2 Sep 2021 16:11 UTC

On Thu, 2 Sep 2021 14:47:26 -0000 (UTC), docdwarf@panix.com () declaimed
the following:

>Starting with clicking the 'Unix File' box on I've tried just about every
>combination and permutation of setting, variations, options and flavors
>the TSO File tab allows: fixed length, VB, Undefined, None and lengths of
>160, 161 and 162 but nothing works; the output winds up as:
>
>FIRST-SHORT-REC(X'25')SECONDREC DATA HERE AS FAR AS IT GOES(X'25')THIRD
>REC HERE FOR SOME MORE(X'25)FOURTH RECORD AT THIS POINT (&c)
>
>That kind of 'striping' of records usually happens when the output LRECL
>and the input don't match (and that kind of fits in with X'25' delimiters
>instead of X'0D0A'.
>

x'25' is an ASCII % sign; I'm surprised it isn't being displayed as
such. It IS a line feed in EBCDIC.
https://www.ibm.com/docs/en/xl-fortran-aix/16.1.0?topic=appendix-ascii-ebcdic-character-sets

Decimal '25', x'19', is "end of medium" for ASCII AND EBCDIC

Note: x'0D0A' is Windows line ending... UNIX/Linux line ending is just
x'0A' -- ASCII line feed (original Macintosh and TRS-80 used x'0D' for
line ending -- carriage return in ASCII and EBCDIC).

You example results also don't seem to show any spacing which would
represent tab characters...

>Is there a setting I'm missing... or is there a quick-and-dirty PC-based
>utility that will get it from variable-length tab-delimited format to
>LRECL 160 with space-padding?

So far your description doesn't fit any format I'm familiar with. I'd
maybe need to see a hex-dump (on the source machine) to see what is really
in the file, since your import attempts may be translating some characters
(for example, converting ASCII x'0A' [Linux line ending standard] into
EBCDIC x'25', but with the lack of ASCII x'0D' is not treating that as a
line-ending).

If the source file really is Linux x'0A' -- there should be some
utility that can change the line ending to x'0D0A' for Windows standard.
(unix2dos being one such, though for one file you could likely even use a
text editor -- VI(M), say -- and do a global find/replace looking for the
linefeed (<ctrl-j>; ^J) and replace with carriage return/linefeed
(<ctrl-m><ctrl-j>; ^M^J).

Any further processing might need one to write a script on the source
OS (I'd suggest Python, using one of the dialects of the "csv" module to
parse the input, and an output statement using fixed width formatting codes
-- you'll have to figure out what widths each field requires).

--
Wulfraed Dennis Lee Bieber AF6VN
wlfraed@ix.netcom.com http://wlfraed.microdiversity.freeddns.org/

Re: [OT] IND$FILE Settings for 'Tab-Delimited' ASCII File

<sgqv7c$lqh$1@reader1.panix.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=189&group=comp.lang.cobol#189

  copy link   Newsgroups: comp.lang.cobol
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!panix!.POSTED.panix1.panix.com!not-for-mail
From: docdwarf@panix.com
Newsgroups: comp.lang.cobol
Subject: Re: [OT] IND$FILE Settings for 'Tab-Delimited' ASCII File
Date: Thu, 2 Sep 2021 16:47:40 -0000 (UTC)
Organization: Public Access Networks Corp.
Message-ID: <sgqv7c$lqh$1@reader1.panix.com>
References: <sgqo5u$2n$1@reader1.panix.com> <qvr1jg9l3lc10en767nfj51qavdlc532eu@4ax.com>
Injection-Date: Thu, 2 Sep 2021 16:47:40 -0000 (UTC)
Injection-Info: reader1.panix.com; posting-host="panix1.panix.com:166.84.1.1";
logging-data="22353"; mail-complaints-to="abuse@panix.com"
X-Newsreader: trn 4.0-test77 (Sep 1, 2010)
 by: docdwarf@panix.com - Thu, 2 Sep 2021 16:47 UTC

In article <qvr1jg9l3lc10en767nfj51qavdlc532eu@4ax.com>,
Dennis Lee Bieber <wlfraed@ix.netcom.com> wrote:
>On Thu, 2 Sep 2021 14:47:26 -0000 (UTC), docdwarf@panix.com () declaimed
>the following:
>
>>Starting with clicking the 'Unix File' box on I've tried just about every
>>combination and permutation of setting, variations, options and flavors
>>the TSO File tab allows: fixed length, VB, Undefined, None and lengths of
>>160, 161 and 162 but nothing works; the output winds up as:
>>
>>FIRST-SHORT-REC(X'25')SECONDREC DATA HERE AS FAR AS IT GOES(X'25')THIRD
>>REC HERE FOR SOME MORE(X'25)FOURTH RECORD AT THIS POINT (&c)

[snip]

> Any further processing might need one to write a script on the source
>OS (I'd suggest Python, using one of the dialects of the "csv" module to
>parse the input, and an output statement using fixed width formatting codes
>-- you'll have to figure out what widths each field requires).

Greatly appreciated, Mr Bieber, but I had to move too quickly to solve it
fast so I had to solve it slowly:

Open the file in Wordpad, save it into a new copy.

Tell IND$FILE that the new file is ASCII CRLF and it loads like a champ.

Thanks much!

DD

1
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor