This general macro writes a record to a file from storage. An option
provides the user with the facility to write either the primary or duplicate
record only.
This macro is for filing records to the online database only and cannot be
used to file records to either general files or general datasets.
The block of storage referred to at the specified entry control block (ECB)
data level or data event control block (DECB) is removed from the ECB.
This macro causes VFA to be searched for the record. If the record
is in VFA, it is forced out of VFA before the new data is written to the
DASD.
The FILSC macro returns the block of storage to the appropriate pool that
is referenced in the core block reference word (CBRW) at the specified ECB
data level or DECB.
Format
- label
- A symbolic name can be assigned to the macro statement.
- datalevel
- An ECB data level (D0-DF) that identifies the file address and core
block information for the I/O request.
- DECB=(reg)|label1
- The label or general register (R0-R7) containing the address of the
DECB, which specifies the file address and core block information for the I/O
request.
- P
- File primary record.
- D
- File duplicate record.
- TAG
- Specify one of the following:
- Y
- The name of the segment that issued the FILSC macro is put into the
storage block to be filed.
- N
- This field is not set.
The default is Y.
Entry Requirements
- R9 must contain the address of the ECB being processed.
- A block of storage must be held by the ECB at the specified ECB data level
(datalevel) or DECB.
- A file address, record ID, and record code check (RCC) must be contained
in the file address reference word (FARW) for the specified ECB data level
(datalevel) or DECB.
Return Conditions
- Control is returned to the next sequential instruction.
- The contents of R14 and R15 are unknown. The contents of all other
registers are preserved across this macro call.
- If this macro is called from a program running in 24-bit mode, the
condition code will be saved across this macro call. If the macro is
called from a program running in 31-bit mode, the condition code upon return
from this macro is unknown.
- The specified CBRW is initialized to indicate that a block of storage is
no longer held.
- The status of the operation is unknown.
- The FARW at the specified ECB data level (datalevel) or DECB is
unchanged.
- The program identification was placed in the header of the record unless
TAG=N was specified.
Programming Considerations
- This macro can be run on any I-stream.
- A check is made by the control program to determine if the ECB is holding
a block of storage at the specified ECB data level or DECB, the file address
contained at the specified ECB data level or DECB is valid, and a duplicate
exists when it is requested. In addition, the record ID at the
specified ECB data level or DECB is checked with the record ID in the
record. If any condition is violated, control is transferred to the
system error routine. When the RCC at the specified ECB data level or
DECB is zero, the control program ignores verification of the RCC. If
the codes are not equal, control is transferred to the system error
routine.
- The block of storage containing the data to be stored is no longer
available to the operational program.
- The status of the output operation cannot be determined by the operational
program.
- The operational program may use the specified CBRW immediately upon return
from the control program.
- In the event of a noncorrectable error, the control program will not
service the request from the alternate device. For example, if the
request for the primary failed, the duplicate will not be updated.
- If the FILSC is issued from a utility program, specifying TAG=N prevents
the utility program name from being inserted in the storage block for
filing. This allows the segment name performing the data manipulation
to be inserted before the call to the utility routine is made, FILSC is
issued, and the name is filed with the data.
- If the location of the data event control block specified by the DECB
parameter does not refer to a valid DECB, control is transferred to the system
error routine.
Examples
None.