From: Ronald Draper on
I want to access an unmountable drive using mf cobol and the physical
drive path. It seems like I should be able to treat the disk as a
single relative record file. Is this doable or just a pipe dream for
some other language?
Thanks
Ron
From: Richard on
On Feb 23, 11:55 am, Ronald Draper <ronald.dra...(a)gmail.com> wrote:
> I want to access an unmountable drive using mf cobol and the physical
> drive path.  It seems like I should be able to treat the disk as a
> single relative record file.  Is this doable or just a pipe dream for
> some other language?

You certainly will not be able to do it as a relative file.

Fixed length relative files may be implemented as fixed size records
but these have a record terminator that indicates whether the record
is valid or deleted.

Variable length relative files (if possible) may be implemented by
having record headers.

Neither of these are useful for looking at disk level sectors.

You are more likely to be able to access the disk by booting into a
Linux Live CD, especially one that is designed for the purpose, such
as SystemRescueCD

http://www.sysresccd.org/Main_Page
From: James J. Gavan on
Ronald Draper wrote:
> I want to access an unmountable drive using mf cobol and the physical
> drive path. It seems like I should be able to treat the disk as a
> single relative record file. Is this doable or just a pipe dream for
> some other language?
> Thanks
> Ron

Much too generalized a question for you to anticipate getting helpful
answers. If I had written, "I use mf and can I do this with a DB ?".
What is your answer ?

So which version of M/F for appropriate compiler, hardware configuration
and does that unmountable have a 'driver' that the OS recognizes. It
*may* just be possible - I really don't know. One factor is you should
look at hard copy or on-line manuals from M/F. Search on the word
'Limitations', covering various topics which include access to disks,
i.e. max disk sizes. You might be screwed before you start.

Jimmy, Calgary AB
From: Rene_Surop on
On Feb 23, 6:55 am, Ronald Draper <ronald.dra...(a)gmail.com> wrote:
> I want to access an unmountable drive using mf cobol and the physical
> drive path.  It seems like I should be able to treat the disk as a
> single relative record file.  Is this doable or just a pipe dream for
> some other language?
> Thanks
> Ron

You could always do it, IF you are asking about the physical drive
path. Code below;

SELECT theFile ASSIGN TO theDrive

:
:

MOVE spaces TO theDrive
STRING "\\theDrive\physicaldrivex" delimited by size
"\myFile.DAT" delimited by size
INTO theDrive

OPEN INPUT theFile

You could always manipulate the drive path using your own style
(variables). What I'm guessing is that you are using the usual Cobol
data structures. You could also change the path size into an IP
address (ie. \\192.168.1.20\physicaldrivex ).
From: Rene_Surop on
Take note however, that SOME devices if it is attached externally
(mobile) are basically opened as a 'read-only' devices... so you would
not able to do some WRITE/REWRITE or OPEN I-O.

Always look at your user privileges on such (mobile) devices before
doing some processing, or else it will fail.