|This article needs additional citations for verification. (August 2012)|
An access method is a function of a mainframe operating system that enables access to data on disk, tape or other external devices. They were introduced in 1963 in IBM OS/360 operating system. Access methods provide an application programming interface (API) for programmers to transfer data to or from device, and could be compared to device drivers in non-mainframe operating systems.
Purpose of access methods
System/360 and successor systems perform input/output using a special program for an I/O channel, a processor dedicated to control peripheral storage device access and data transfer to and from main memory. These channel programs are composed of special instructions, called channel command words (CCWs). Programming those is a complex task requiring detailed knowledge of the hardware characteristics. Channel programs are initiated by a STARTIO macro issued by the operating system. This is usually front ended by the Execute Channel Program (EXCP) macro for application programmer convenience. This macro issues an SVC (supervisor call instruction) that directs the operating system to issue the STARTIO on the application's behalf.
Access methods provide:
- Ease of programming - programmer would no longer deal with a specific device procedures, including error detection and recovery tactics in each and every program. A program designed to process a sequence of 80-character records would work no matter where the data are stored.
- Ease of hardware replacement - programmer would no longer alter a program when data should be migrated to newer model of storage device, provided it supports the same access methods.
- Ease shared data set access - an access method is a trusted program, that allows multiple programs to access the same file, while ensuring the basic data integrity and system security.
Storage access methods
Storage-oriented access methods in approximate chronological order:
- BDAM - Basic direct access method
- BSAM - Basic sequential access method
- QSAM - Queued sequential access method
- BPAM - Basic partitioned access method
- ISAM - Indexed sequential access method
- VSAM - Virtual storage access method, introduced with OS/VS
- OAM - Object access method, introduced in MVS/SP (1989)
Basic versus queued
Both types of access deal with records of a data set. Basic access methods read or write one physical record – block – at a time. Queued methods support internal blocking of data and also often read-ahead scheme. Queued access methods generally provide better performance, while basic methods provide more flexibility.
Sequential versus direct
Sequential access assumes that records can be processed only sequentially, as opposed to direct (or random) access. Some devices, such as magnetic tape, naturally enforce sequential access, but it can be used as well on direct access storage devices (DASD), such as disk drives. In the latter case, a data set written with sequential access can be later processed in a direct manner.
Networking access methods
Network-oriented access methods in approximate chronological order:
- BTAM - Basic telecommunications access method
- QTAM - Queued teleprocessing access method
- TCAM - Telecommunications access method
- VTAM - Virtual telecommunications access method, introduced with OS/VS
The IBM Information Management System (IMS) uses the term "access method" to refer to its methods for manipulating "segments in a database record." These are: Generalized Sequential Access Method (GSAM), Hierarchical Direct Access Method (HDAM), Hierarchical Indexed Direct Access Method (HIDAM), Hierarchical Indexed Sequential Access Method (HISAM), Hierarchical Sequential Access Method (HSAM), Partitioned Hierarchical Direct Access Method (PHDAM), Partitioned Hierarchical Indexed Direct Access Method (PHIDAM), Partitioned Secondary Index (PSIMDEX), Simple Hierarchical Sequential Access Method (SHSAM), and Simple Hierarchical Indexed Sequential Access Method (SHISAM). This is a different use of the term from the other access methods mentioned in this article.
In the z/OS operating system, two elements provide access methods:
- Data Facility Product
- Communications Server
- M. A. Auslander, D. C. Larkin, A. L. Scherr: "The Evolution of the MVS Operating System", pages 478-479
-  ABCs of z/OS System Programming Volume 3
- IBM Corporation. "Types of IMS databases". Retrieved September 4, 2011.