On Mon, 18 Nov 2002 12:46:44 -0600 (Central Standard Time), Tom Emerson <[log in to unmask]> wrote: I think I got a lot of misconceptions from http://www.hp.com/products1/mpeixservers/info_library/wp/ksam_mpe.pdf >you don't control that behaviour this way -- since "all files" are record >oriented, FOPEN always opens them with some idea of the record size. The >FREAD intrinsic reads the next available record (in effect, defaulting to >sequential access). To MOVE to another record (i.e., "direct access") you >use the FREADDIR intrinsic to read a specific record, or FSEEK to point to >the record you want prior to reading it. So I don't have to open the standard file in any special way - I just use the appropriate intrinsic to achieve either direct or sequential access? I got confused due to the following text from that pdf file - ---- * If a program opens a standard file for sequential input,the records will be read in the order they ’re stored,(i.e.the order in which they were written). * Programs may also open standard files using direct access.This permits a program to read or write a record based on its relative record number.So, for example,a program can read the nth record in a file without having to first read the n - 1 records preceding it. ------ This implied to me that you had to do something on the FOPEN. >> Also, FDELETE will delete a record from a RIO file. How do you delete >> a record from a direct access standard file? > >The simple answer is "you don't" ...<snip> I had an e-mail which agrees with you but I've got this text from that PDF file - -------------- RIO files (relative I/O) RIO is an enhanced form of relative access.If a program opens a standard file for direct access,it must know the relative record number of the record it ’s interested in.If multiple processes are accessing the same file,relative record numbers can change dynamically. For example,if process "A " deletes relative record number n ,then all the records after n will have their relative record number adjusted by one.This can make things very difficult for a hypothetical process "B " that is trying to access the same file at the same time..The relative record numbers of the records that "B " is interested in could be changing even as "B " is accessing them.. -------------- So that explains the problems associated with deleting records from standard files but I can't find an intrinsic to do it. It goes on to explain about RIO files and how they leave a marker - as you explain too. Hope I don't come across as wanting an argument! I'd just like to be clear on what's happening. Thanks for your replies. Peter -- http://www.wadmag.org.uk - Windsor & District MAG http://www.nmmcc.co.uk - Non-Members MCC http://uk.geocities.com/ukwebring - UK Motorcycle site webring * To join/leave the list, search archives, change list settings, * * etc., please visit http://raven.utc.edu/archives/hp3000-l.html *