Specifying a Non-Default File ID

How to:

If the FOCUS data source has a file ID other than the default, issue the USE command to identify the data source, with its file specifications, and associate it with a specific Master File.


Top of page

x
Syntax: How to Specify a Non-Default File ID
fileid AS mastername 
END

where:

fileid

Is any valid file specification for the specific operating system.

mastername

Is name of the Master File name that will be associated with the file ID.



Example: Specifying Different File Names

To read the data source with the name EMP026 described by the Master File EMPLOYEE, enter this USE command:

For CMS:

USE
EMP026 FOCUS A AS EMPLOYEE
END

 

For z/OS:

USE
EMP026 AS EMPLOYEE
END

After entering the USE command, you can read the EMP026 data source by entering the command TABLE FILE EMPLOYEE.



Example: Specifying Different File Types and Extensions

For CMS:

To read the data source with the name EMP026 and a file type of DATA on the A-disk, described by the Master File EMPLOYEE, enter this USE command:

USE
EMP026 DATA A AS EMPLOYEE
END

After entering the USE command, you can read the EMP026 data source by entering the command TABLE FILE EMPLOYEE.



Example: Specifying Different File Locations

For CMS:

To read the data source with the name EMP026 located on the F disk, described by the Master File EMPLOYEE, enter this USE command:

USE
EMP026 FOCUS F AS EMPLOYEE
END

The first data source in the USE directory defines the default file type and file mode for the rest of the session or until you clear the USE directory. For example, if you later issue the command TABLE FILE PRODUCT, FOCUS searches for the data source PRODUCT FOCUS F even if you did not specify the data source in the USE command. If you want to read both EMPLOYEE FOCUS F and PRODUCT FOCUS A, issue:

USE
EMP026 FOCUS F AS EMPLOYEE
PRODUCT FOCUS A
END

Since PRODUCT FOCUS A is the second entry in the USE directory, the default file mode remains F.


Information Builders