You can find out the current SDF options for your task, such as the input mode, scope of logging, or command history. To do this, enter a question mark followed by
to open the selection menu with the application domains. The command you require belongs to domain number 19 (SDF). There you select the SHOW-SDF-OPTIONS command by entering the number 10 in the NEXT input field and sending off the menu with .The operand form for the command appears. In the INFORMATION input field, which contains the default value *ALL, enter *user and send off the form with
.SDF outputs the SDF options of your task. INFORMATION=*USER gives you only SDF options which you can modify yourself using the MODIFY-SDF-OPTIONS command.
The INPUT-HISTORY output field with the value *ON indicates that the command history is activated. The INPUT-BUFFER-SIZE output field indicates that SDF saves only the last 20 inputs.
In one of the following examples, SDF accesses the command history. If INPUT-HISTORY has the value *OFF on your screen, you can activate the command history by, for example, making use of the abbreviation options and entering directly “mod-sdf-opt input=*on”. Alternatively, you can request the operand form in temporarily guided dialog and change the value for INPUT-HISTORY accordingly.
Creating a logon procedure
Write yourself a short procedure which, after logon, automatically displays all files which have not been accessed for at least 20 days. You must save the commands which comprise the procedure to a file with the default name SYS.SDF.LOGON.USERPROC under your user ID. The default name causes SDF to call the procedure automatically after logon (see the description of logon procedures on "Input from procedures "). To create the procedure file, call the (editor) program EDT1. “?” followed by opens the selection menu containing the application domains. “17” followed by displays the commands of the PROGRAM domain. takes you one screen further (the NEXT line is already preset to “+“). To start the program, enter “34” in the subsequent screen to issue the START-EXECUTABLE-PROGRAM2 command and send off the menu with .
1The utility routine EDT can also be called with the START-EDT command.
2The command is available in BLSSERV V2.3 and higher and will replace the START-PROGRAM command in the long term.
Alternatively, you can start, for example, with the input “*prog*?” instead of “?”. You will receive a selection menu containing all commands whose name contains the word PROGRAM (see section “Selection menu for commands and statements”). Enter “8” to select the START-EXECUTABLE-PROGRAM command.
In both cases you will receive the operand form of the START-EXECUTABLE-PROGRAM command. In the FROM-FILE input field, enter the program name $.EDT. This is the name of the file from which the program EDT will be loaded (in this case the file EDT in the system default ID; if the name differs from this, you can find it out from system administration).
Once EDT is loaded, the EDT screen mask is displayed.
In the input fields 1.00 to 2.00, enter the specified commands. The WRITE-TEXT command outputs the specified text to SYSOUT. It provides a comment on the file selection of the SHOW-FILE-ATTRIBUTES command.
To save the input as the file SYS.SDF.LOGON.USERPROC, enter the command “write’sys.sdf.logon.userproc‘” in the last line of the EDT mask and send off the mask with .
The EDT mask is displayed again, confirming via message EDT0173 that the file SYS.SDF.LOGON.USERPROC has been created. If the file already exists, EDT asks beforehand whether it is to be overwritten.
To terminate EDT, enter “halt” in the last line and press .
To check the procedure, call it up with “call-proc sys.sdf.logon.userproc”.
This direct input makes use of the abbreviation mechanism (abbreviation of the command name CALL-PROCEDURE; specification of the procedure file as the first positional operand because NAME is the first operand in the command). Alternatively, you can use the method employed previously: Input “?” -> “16” (PROCEDURE) ->
Select CALL-PROCEDURE ->
Enter file name under FROM-FILE.
Reconstructing a command
Let us suppose you have made a mistake when calling the SYS.SDF.LOGON.USERPROC procedure (see previous example), e.g. you have entered an incorrect file name.
In this case, you can redisplay the errored input using “restore-sdf”, one of the possible abbreviations of the RESTORE-SDF-INPUT command.
Correct the file name in the command line by, for example, positioning the cursor after “sys.sdf.log”, pressing the
(insert) key and inserting the missing letter “o”. Now send off this corrected command line with .Terminating an interactive task
Terminate the interactive task with the EXIT-JOB command. When you enter “exit-job?”, SDF changes to temporarily guided dialog and outputs the operand form of the command.
You can also display the operand form by entering the following:
“?”
“11” (JOB)
Select EXIT-JOB.
As you will need to log on again in the following example, change the value in the KEEP-CONNECTION input field to *YES before you send off the menu with . This ensures that the system remains connected when the task is finished and you can log on again immediately.
Starting an interactive task
When you have terminated your interactive task (see previous example), the system prompts you to log on again. Enter “?” and
Because you must first log on to the system with SET-LOGON-PARAMETERS before entering further commands, SDF immediately displays the operand form. The input “set-logon-parameters?” has the same effect. Enter your user ID, account number and password. You can enter a job name if you wish.
In the last line SDF informs you that you can obtain an overview of all other commands with *EXIT. You can trigger an *EXIT by pressing the key (see the function key assignment in the KEYS line1), or you can enter *EXIT in the NEXT line and then press the key. With *EXIT you quit the operand form and switch to a selection menu which contains all the commands you may use before logging on. These, however, are only the commands EXIT-JOB and LOGOFF to terminate the task, and the SET-LOGON-PARAMETERS command for logging on.
After checking the logon details, SDF starts your logon procedure.
1The “KEYS” field name is only displayed in the Styleguide mode. If you have set the old mode (because your terminal does not support the Styleguide mode, for example), then the possible entries and corresponding function key assignments will be displayed anyway, but there are fewer function keys available. Note that in the old mode *EXIT corresponds to the
key.If you are already familiar with the SET-LOGON-PARAMETERS command, you can also log onto the system directly. To do this, enter the command with the necessary specifications and send it off with
. For security reasons you should enter the operand value *SECRET instead of your password. SDF will then provide a protected input field for you to enter your password.Notes
The examples in this chapter could only show you some of the most important input options. We have only shown you input in unguided dialog and the switch to temporarily guided dialog.
However, SDF also allows you to work permanently in guided dialog. A sample session with all modes of guidance is described in chapter “Examples of command input in interactivemode” (Examples of command input in interactive mode ).
The input options, in particular abbreviation rules, guidance levels, menu control and the definition of task-specific default values, are described in chapter “Input of commands andstatements” (Input of commands and statements ).
The functional scope (permitted commands, operands and operand values) available to you is defined in syntax files. The meanings of the syntax files are described in chapter“SDF syntax files”.
If your procedures still contain commands from the previous command language ISP, the SDF-CONV utility routine supports you in converting these to SDF commands. If you enter an ISP command followed by a question mark in interactive mode, SDF helps to find the corresponding ISP command: if there is just one corresponding SDF command, its operand form will be displayed; if exact mapping is not possible, SDF outputs a list of possible SDF commands.