* RE: VMS help needed
1996-01-18 5:00 VMS help needed Harry Dodsworth
@ 1996-01-18 5:00 ` oberman
1996-01-18 5:00 ` Brian Tillman
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: oberman @ 1996-01-18 5:00 UTC (permalink / raw)
In Article <DLCy16.Dw3@freenet.carleton.ca>
af877@FreeNet.Carleton.CA (Harry Dodsworth) writes:
>
>
> I'm new to VMS and have what seems to be a simple problem that
>I can't solve.
>
> I have variable length records, 461 bytes long that I want to
>print. The PRINT command prints 132 characters and the rest is
>lost.
> When I display them on the screen with a TYPE command, they
>wrap fine. I used TYPE and saved them to a file but the system
>was smart enough to know they were 461 byte records so no print!
>
> So how do you print all of records longer than 132 characters?
>
>One of them displays with part of the record offset by five bytes;
>I think it might have a TAB or similar control character in a
>character field; how do I display a record in hexadecimal so I can
>see what is really there?
This is kind of messy. Width is set in several places. First, for serial
printers, the terminal specification set maximum record length. (Show/Set
Terminal.) For parallel printers, see SHOW/SET PRINTER. Finally and probably
most importantly, the queue form setup defines how the print symbiont handles
long records. It can wrap or truncate at any line length. See DEFINE/FORM. You
can define various forms of different widths and other characteristic and
specify the one to use in the PRINT command.
If you are using DECprint, things are done with "LAYUP" files, but I suspect
you are not using DECprint.
R. Kevin Oberman
Energy Sciences Network (ESnet)
National Energy Research Supercomputer Center (NERSC)
Internet: oberman@es.net +1 510-422-6955
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: VMS help needed
1996-01-18 5:00 VMS help needed Harry Dodsworth
1996-01-18 5:00 ` oberman
@ 1996-01-18 5:00 ` Brian Tillman
1996-01-18 5:00 ` Excellence is an attitude
1996-01-20 5:00 ` Aaron Leonard
3 siblings, 0 replies; 5+ messages in thread
From: Brian Tillman @ 1996-01-18 5:00 UTC (permalink / raw)
In article <DLCy16.Dw3@freenet.carleton.ca>, af877@FreeNet.Carleton.CA says...
>
> I have variable length records, 461 bytes long that I want to
>print. The PRINT command prints 132 characters and the rest is
>lost.
> When I display them on the screen with a TYPE command, they
>wrap fine. I used TYPE and saved them to a file but the system
>was smart enough to know they were 461 byte records so no print!
>
> So how do you print all of records longer than 132 characters?
Thr form mounted on the printer you're using probably has /TRUNCATE defined
for it. (Use SHOW QUEUE/FORM/FULL formname to see it.) Have the system
administrator redefine the form with /NOTRUNCATE.
>One of them displays with part of the record offset by five bytes;
>I think it might have a TAB or similar control character in a
>character field; how do I display a record in hexadecimal so I can
>see what is really there?
>
$ dump file
--
-----------------------------+--------------------------------
Brian Tillman | Internet: tillman@swdev.si.com
Smiths Industries, Inc. | tillman_brian@si.com
4141 Eastern Ave., MS239 | Hey, I said this stuff myself.
Grand Rapids, MI 49518-8727 | My company has no part in it.
-----------------------------+--------------------------------
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: VMS help needed
1996-01-18 5:00 VMS help needed Harry Dodsworth
1996-01-18 5:00 ` oberman
1996-01-18 5:00 ` Brian Tillman
@ 1996-01-18 5:00 ` Excellence is an attitude
1996-01-20 5:00 ` Aaron Leonard
3 siblings, 0 replies; 5+ messages in thread
From: Excellence is an attitude @ 1996-01-18 5:00 UTC (permalink / raw)
Harry,
Your question would probably be better served if posted in the comp.os.vms
group as it is focused on OpenVMS issues.
One approach to print the rather large records in your file is:
$ TYPE/OUTPUT=foo.lis bar.file
$ PRINT foo.lis
where you replace the lowercase file names with names of your own.
I am assuming bar.file is the name of your existing file and foo.lis is just a
temporary file used to 'pipe' the data.
You can view the actual file contents using the DUMP command. Use HELP DUMP
for details.
$ DUMP bar.file
will probably do exactly what you wish.
Have fun,
don
In article <DLCy16.Dw3@freenet.carleton.ca>, af877@FreeNet.Carleton.CA
(Harry Dodsworth) writes:
>
>
> I'm new to VMS and have what seems to be a simple problem that
> I can't solve.
>
> I have variable length records, 461 bytes long that I want to
> print. The PRINT command prints 132 characters and the rest is
> lost.
> When I display them on the screen with a TYPE command, they
> wrap fine. I used TYPE and saved them to a file but the system
> was smart enough to know they were 461 byte records so no print!
>
> So how do you print all of records longer than 132 characters?
>
> One of them displays with part of the record offset by five bytes;
> I think it might have a TAB or similar control character in a
> character field; how do I display a record in hexadecimal so I can
> see what is really there?
>
> Harry Dodsworth Ottawa Ontario Canada af877@freenet.carleton.ca
> ----------------------------------------------------------------
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: VMS help needed
1996-01-18 5:00 VMS help needed Harry Dodsworth
` (2 preceding siblings ...)
1996-01-18 5:00 ` Excellence is an attitude
@ 1996-01-20 5:00 ` Aaron Leonard
3 siblings, 0 replies; 5+ messages in thread
From: Aaron Leonard @ 1996-01-20 5:00 UTC (permalink / raw)
In article <DLCy16.Dw3@freenet.carleton.ca>, af877@FreeNet.Carleton.CA (Harry Dodsworth) writes:
|
|
| I'm new to VMS and have what seems to be a simple problem that
|I can't solve.
|
| I have variable length records, 461 bytes long that I want to
|print. The PRINT command prints 132 characters and the rest is
|lost.
| When I display them on the screen with a TYPE command, they
|wrap fine. I used TYPE and saved them to a file but the system
|was smart enough to know they were 461 byte records so no print!
|
| So how do you print all of records longer than 132 characters?
Sounds like you just need to write a little program to wrap your
records. You could do this in DCL or TPU or C or whatever you
have & are handy with. (See DCL below for an example.)
|One of them displays with part of the record offset by five bytes;
|I think it might have a TAB or similar control character in a
|character field; how do I display a record in hexadecimal so I can
|see what is really there?
$ DUMP/RECORD
should do the trick. See HELP DUMP for the various options.
Regards,
Aaron
Aaron Leonard MultiNet-VMS@Support.TGV.COM [ work ]
Leonard@Leonard.Tucson.AZ.US [ home ]
---
$! wrap.com
$! wrap file at some right margin
$! usage: @wrap reclength infile outfile
$! Note: not sure of the actual maximum record length this can handle
$!
$ reclength = f$integer(p1)
$ if reclength .le. 0 .or. reclength .gt. 1023
$ then
$ inquire/nopunct reclength "reclength [1 - 1023]: "
$ endif
$ infile = p2
$ if infile .eqs. "" then $ inquire infile
$ outfile = p3
$ if outfile .eqs. "" then $ inquire outfile
$ open /read/error=errexit inf 'infile'
$ open /write/error=errexit outf 'outfile'
$readloop:
$ read /error=errexit /end=readall inf inrec
$ inreclen = f$length(inrec)
$ pos = 0
$writeloop:
$ write outf f$extr(pos, reclength, inrec)
$ if pos+reclength .ge. inreclen then $ goto readloop
$ pos = pos + reclength
$ goto writeloop
$readall:
$ close outf
$ close inf
$ exit 1
$errexit:
$ sts = $status
$ close/nolog outf
$ close/nolog inf
$ write sys$error "file error"
$ exit sts
^ permalink raw reply [flat|nested] 5+ messages in thread