Previous Topic: Data Manipulation Language StatementsNext Topic: #ABEND—terminates the issuing task abnormally


Functions of DML Statements

The data manipulation language enables you to access the database management system (DBMS) and to request LRF and DC/UCF services from your Assembler program. The DML statements can be grouped into 14 categories by function:

The following table groups the DML statements by function and gives a brief description of each command.

DML Statements Grouped by Function

Function

DML statement

Description

Control Statements

@BIND SUBSCH

Signs on the application program to the CA IDMS/DB database management system

 

@BIND REC

Establishes addressability in variable storage for one or more records included in the program's subschema

 

@BIND PROC

Establishes communication between the application program and a DBA-defined database procedure

 

@READY

Prepares database areas for processing

 

@FINISH

Commits changes made to the database through an individual run unit and terminates the run unit

 

@IF

Evaluates the presence of records in a set and specifies action based on the outcome

 

@COMMIT

Commits changes made to the database by an individual run unit

 

@ROLLBAK

Rolls back uncommitted changes made to the database through an individual run unit

 

@KEEP

Places locks on record occurrences

Retrieval Statements

@FIND/OBTAIN DBKEY

Accesses a record by using a db-key previously saved by the program

 

@FIND/OBTAIN CURRENT

Accesses a record by using established currencies

 

@FIND/OBTAIN WITHIN SET/AREA

Accesses a record based on its logical location within a set or its physical location within an area

 

@FIND/OBTAIN OWNER

Accesses the owner record of a set occurrence

 

@FIND/OBTAIN CALC/DUPLICATE

Accesses a record by using its CALC-key value

 

@FIND/OBTAIN USING SORT KEY

Accesses a record in a sorted set by using its sort-key value

 

@GET

Moves all data associated with a previously located record into program variable storage

Modification Statements

@STORE

Adds a new record to the database

 

@MODIFY

Changes the contents of an existing record

 

@CONNECT

Links a record to a set

 

@DISCON

Removes a member record from a set

 

@ERASE

Deletes a record from the database

Accept Statements

@ACCEPT DBKEY FROM CURRENCY

Saves the db-key of the current record of run unit, record type, set, or area

 

@ACCEPT DBKEY RELATIVE TO CURRENCY

Saves the db-key of the next, prior, or owner record relative to the current record of a set

 

@ACCEPT PAGE INFORMATION FOR A GIVEN RECORD

Saves the page information for a record current record of a set

 

@ACCEPT STATS

Returns system runtime statistics to the program

 

@ACCEPT BIND

Returns a record's bind address to the program

 

@ACCEPT PGINFO

Returns page information for a given record to the program

 

@ACCEPT PROC

Returns information in the application program information block associated with a database procedure to the program

 

@RETURN

Retrieves a database key of a record entry that has been indexed under integrated indexing.

Logical Record Facility (LRF) Statements

@OBTAIN logical-record @MODIFY logical-record @STORE logical-record @ERASE logical-record

Retrieves a logical record Modifies a logical record Stores a new logical record Deletes a logical record

Program Management Statements

#LINK

Passes control to another program with the expectation of receiving it back

 

#RETURN

Returns control to the next higher level calling program

 

#LOAD

Loads a program or table into the program pool

 

#DELETE

Signals that the program has finished using a program or table in the program pool

 

#STAE

Establishes linkage to a program or routine that will receive control in the event of an abend

 

#ABEND

Abnormally terminates the issuing task

 

#XCTL

Passes control to another program with no expectation of having it returned

Storage Management Statements

#GETSTG

#FREESTG

Allocates variable storage from a DC/UCF storage pool Frees all or part of a block of variable storage

Task Management Statements

#ATTACH

Attaches a new task within the DC/UCF system

 

#CHAP

Changes the dispatching priority of the issuing task

 

#ENQ

Acquires a resource or a list of resources

 

#DEQ

Releases a resource

 

#WAIT

Relinquishes control to the system while awaiting the completion of an event

 

#POST

Posts an event control block

Time Management Statements

#GETIME

Obtains the time and date from the system

 

#SETIME

Defines a timed event

Scratch Management Statements

#PUTSCR #GETSCR #DELSCR

Stores a scratch record Retrieves a scratch record Deletes a scratch record

Queue Management Statements

#PUTQUE #GETQUE #DELQUE

Stores a queue record Retrieves a queue record Deletes a queue record

Terminal Management (Basic Mode)

#TREQ

Transfers data and device dependent information to or from the terminal, or establishes a terminal request block (TRB) for use by subsequent #TREQ operations. The #TREQ statement can be used to communicate in an SNA network environment

Terminal Management (Line Mode)

#LINEIN

Requests a synchronous data transfer from the terminal to the issuing program

 

#LINEOUT

Requests a synchronous or asynchronous data transfer from the issuing program to the terminal

 

#LINEEND

Terminates the current line I/O session

Terminal Management (Mapping Mode)

#MREQ

Requests a transfer of data from the issuing program to the terminal and/or vice versa

 

#MAPINQ

Obtains information or tests conditions concerning the previous map operation

 

#MAPMOD

Requests modifications of mapping options for a map

 

#STRTPAG

Begins a map paging session and specifies options for that session

 

#ENDPAG

Terminates a map paging session

Terminal Management (Print Mode)

#PRINT

Transfers data from a task to a terminal defined as a printer.

Utility Functions

#ACCEPT

Retrieves task-related information

 

#SNAP

Requests a memory dump of selected parts of storage

 

#SENDMSG

Sends a message to a user, logical terminal, list of users, or list of logical terminals

 

#TRNSTAT

Requests or terminates statistics collection; retrieves transaction statistics into program storage

 

#KEEP

Enables database locks or database monitoring for records, sets, or areas or terminates a prior #KEEP request

 

#WTL

Retrieves a message from the dictionary and sends it to a predefined destination

Recovery Statements

#COMMIT

Commits changes made to the database through an individual run unit or through all database sessions associated with a task

 

#FINISH

Commits changes made to the database through an individual run unit or through all database sessions associated with a task

 

#ROLLBAK

Rolls back uncommitted changes made to the database through an individual run unit or through all database sessions associated with a task

 

#PUTJRNL

Writes user-defined records to the journal file