Previous Topic: SWAPNext Topic: UPDATE


SWITCH

The SWITCH command allows you to transfer directly from one development tool to another under the Transfer Control Facility (TCF). For example, while under TCF you can use SWITCH to transfer from IDD to ADSC without having to return to the TCF Selection Screen. Use SWITCH to perform any of the following operations:

Note: For more information about the TCF, see Transfer Control Facility.

Syntax

►►─── SWItch ─┬───────────────────────────────┬───────────────────────────────►◄
              ├─┬─ product-code ─┬──┬───────┬─┤
              │ └─ task-code ────┘  ├─ OLD ◄┤ │
              │                     └─ NEW ─┘ │
              ├─ tcf-task-code ───────────────┤
              ├─┬─ CLEar ─┬───────────────────┤
              │ └─ CLR ───┘                   │
              └─ SUSpend ─────────────────────┘

Parameters

SWItch

Suspends the current development tool session. Control transfers back to the most recently suspended development tool session. If no suspended session exists, SWITCH transfers control to the TCF Selection Screen.

product-code

Specifies the development tool to which control should transfer.

Product-code identifies a development tool by a unique system-supplied invocation name defined at system generation on the TASK statement.

For example, IDD is the product code for online IDD; SSC is the product code for the online subschema compiler.

Product codes are defined for use only within TCF.

task-code

Identifies a development tool by its unique installation-defined invocation name.

For example, IDDT has been defined as the task code for online IDD; SSCT has been defined as the task code for the online subschema compiler. Task codes are defined at system generation time and can vary from site to site.

OLD

OLD, the default, resumes the most recently suspended session of the specified development tool. If no suspended session exists, OLD starts a new session of the development tool.

NEW

Starts a new session of the specified development tool.

Note: If you have a suspended IDD menu facility, online IDD, schema compiler, subschema compiler, or system generation compiler session, NEW resumes that suspended session. This is because you can have only one suspended session of each of these tools.

Note: The OLD and NEW options are not valid with the ADSA, ADSC, and MAPC task codes.

tcf-task-code

Specifies the task code that invokes the TCF. When you specify it with the SWITCH command, the TCF Selection Screen displays.

Tcf-task-code must be defined at system generation time and can vary from site to site. The default task code is TCF.

A sample TCF Selection Screen is shown at the end of these SWITCH command syntax rules.

CLEar and CLR

Suspends the development tool session, ends the TCF session (clearing the list of suspended sessions and DB defaults), and returns control to DC/UCF.

Your suspended development tool sessions are not affected by this action. You can resume any of your suspended sessions by invoking the appropriate development tool (while under TCF or directly from the DC/UCF system) and specifying the name of the definition being created in the suspended session. These suspended sessions exist until you sign off from the host TP monitor or the DC/UCF system terminates.

Note: The CLEar and CLR options are not used with ADSAT, ADSCT, or MAPCTtask codes.

SUSpend

Suspends the development tool session, suspends the TCF session (saving the list of suspended sessions and DB defaults), and returns control to DC/UCF.

Note: The ADSA, ADSC, and MAPC compilers automatically suspend sessions (and save the contents of the session in queue records) when you leave the compiler. Therefore, the SUSPEND option has no affect when used with ADSA, ADSC, or MAPC.

Your list will be available to you next time you invoke TCF. The list of suspended sessions is saved by TCF when you sign off from the host TP monitor or the DC/UCF system terminates.

You can resume any of your suspended development tool sessions by selecting the session from your list of suspended sessions (while under TCF). You also can resume any suspended session by invoking the appropriate development tool (while under TCF or directly from the DC/UCF system) and specifying the name of the definition being created in the suspended session.

Note: Do not use SUSPEND to exit the schema or subschema compilers if you are using the Automatic System Facility (ASF) in the same online session. In this case, use END or the signoff command.

Example

You display the TCF Selection Screen by specifying the SWITCH tcf-task-code.

The TCF Selection Screen provides the following information:

CA,INC. TRANSFER CONTROL FACILITY *** SELECTION SCREEN *** _ SUSPEND TCF SESSION (PF9) DBNAME..: DBNODE..: _ TERMINATE TCF SESSION (PF3) DICTNAME: TSTDICT DICTNODE: *TCF TASKCODES* *SUSPENDED SESSIONS* SELECT ONE TO START A NEW SESSION SELECT ONE TO RESUME AN OLD SESSION TASKCODE DESCRIPTOR _ TCF _ SYSGENT SYSGEN COMPILER _ MAPCT MAP DEFINITION _ ADSCT DIALOG COMPILER _ ADSAT APPLICATION COMPILER _ ASF _ ASFT _ IDDT IDD COMMAND MODE _ SSCT SUBSCHEMA COMPILER _ SCHEMAT SCHEMA COMPILER _ IDDMT IDD MENU MODE _ OLQ OLQ COMMAND MODE _ OLQT OLQ COMMAND MODE

Product and Task Code Usage

In a SWITCH command, you can specify a development tool's product or task code to transfer to that development tool. Additionally, you can use a task code defined for use under TCF to invoke the associated development tool directly from a DC/UCF system.

The following table lists product codes and sample task codes for use under TCF.

Development Tool

Product Code

Sample Task Code1

Site Task Code

CA ADS application compiler (ADSA)

ADSA

ADSAT

 

CA ADS dialog compiler (ADSC)

ADSC

ADSCT

 

ASF

ASF

ASFT

 

IDD menu facility

IDDM

IDDMT

 

Online IDD

IDD

IDDT

 

Online map compiler (MAPC)

MAPC

MAPCT

 

Online command facility (OCF)

OCF

OCFT

 

CA OLQ

OLQ

OLQT

 

Online schema compiler

SCHEMA

SCHEMAT

 

Online subschema compiler

SSC

SSCT

 

Online system generation compiler

SYSGEN

SYSGENT

 

1. Task codes for use under TCF are defined at system generation time and can vary from site to site.

SWITCH Command Specification Outcomes

Use SWITCH to transfer from one development tool session to another new or suspended development tool session, to the TCF Selection Screen, or back to the DC/UCF system.

The following table shows the outcome for each SWITCH specification.

SWITCH command specification

If you have suspended session(s)

If you do not have suspended session(s)

SWITCH

Resumes most recently suspended development tool session

Displays TCF Selection Screen

SWITCH product or task code OLD

Resumes most recently suspended session of requested tool

Starts new session of requested tool if tool is IDD or online compiler or displays DC/UCF screen if tool is ADSA, ADSC, or MAPC

SWITCH product or task code NEW

Resumes most recently suspended session of requested tool (IDD and online compilers only)

Starts new session of requested tool, if possible

SWITCH tcf-task-code

Displays TCF Selection Screen

Displays TCF Selection Screen

SWITCH CLEAR

Clears list of suspended development tool sessions and displays DC/UCF screen

Displays DC/UCF screen

SWITCH SUSPEND

Saves list of suspended development tool sessions and displays DC/UCF screen

 

Using the SWITCH Command

How to Specify the SWITCH Command

Specify the SWITCH command on the command line in a given development tool. For example, specify SWITCH as a top-line command in IDD.

When using ADSA, ADSC, or MAPC, you can also select the SWITCH activity from the action bar of the main menu.

Using SWITCH with Other Development Tools

When operating under TCF, you can specify SWITCH and any optional parameters in any development tool presented in this table.

The following table describes methods for specifying SWITCH in development tools under TCF.

Development Tool

Specifying the SWITCH Command

Specifying Optional Parameters

ADSA, ADSC, MAPC

Select the SWITCH activity from the action bar of the main menu or

Type SWITCH in the command line.

  • Specify a task or product code on the TASK ID field of the SWITCH activity.
  • Specify a task code or product code as a SWITCH parameter on the command line.

Example: switch idd

IDD

Type SWITCH in the command line.

  • Specify a product code or task code as a SWITCH parameter.
  • Specify OLD or NEW as a parameter after a product or task code.

Example: switch sysgen old

OLQ

Type SWITCH in the command line.

  • Specify a task code as a SWITCH parameter

Example: switch schema

Online schema, subschema, and system generation compilers, and the OCF

Type SWITCH in the command line.

  • Specify a product code, task code, or keyword as a SWITCH parameter.
  • Specify OLD or NEW as a parameter after a product or task code.

Example: switch idd new