Previous Topic: Defining ViewsNext Topic: Step 2: Specifying the Source Tables and Join Criteria


Step 1: Naming the View

Name the View

The Activity Selection screen is displayed. The JOB and APPLICANT tables should be listed in the table directory. Type the new table name, jobs and applicants, in the Table Name field:

                TABLE NAME.:  jobs and applicants
                TABLE OWNER:  SNELL

Remember that the table name can be any alphanumeric combination, including embedded spaces, of up to 32 characters.

Now that you have named the view, select the Define Table function ([PF2]) from the activity selection menu.

Replace 'Stored' with 'View'

The Table Definition screen is now displayed. Notice that the table name JOBS AND APPLICANTS is in the Table Name field. Your user ID is in the Table Owner field. The View/Stored field below the Table Owner field contains the default value of STORED.

The cursor is positioned at the View/Stored field. Type view in place of STORED:

    CA   TDEF   CA - Automatic System Facility            ** Table Definition **   DC560203 TABLE UNDEFINED          _ PF1 - Help                     _ PF4 - Extended Table Definition          _ PF2 - Define Columns           _ PF5 - Delete Table Definition          _ PF3 - Generate                 _ PF6 - Message Screen   Table Name.: JOBS AND APPLICANTS   Table Owner: SNELL                                  Defn Number:   View/Stored: view                                  Status.....: NEW   Comments...:

ASF Adds a New Table

Press [Enter]. The message TABLE ADDED displays on the message display line. The Defn Number field to the right of the Table Owner field displays the definition number for the table. The Status field below the Defn Number field has changed from NEW to UNGENERATED.

Now you are ready to specify both the source tables from which the view is being derived and the criteria on which the source tables are being joined.