The tutorial is organised into the following lessons. Note that you should work through the lessons in sequence, because later lessons assume familiarity with techniques learned in earlier lessons and some lessons use programs or procedures created in previous lessons. The content of the eight lessons is as follows:
Lesson 1: A Heading Display
You create a simple batch program that displays a screen heading. Unfortunately the
heading disappears as soon as it is sent to the screen, because the screen clears when the
program ends, but in the next lesson we shall overcome this difficulty. The principal
purpose of this lesson is to familiarise you with the QA Build development cycle.
Lesson 2: A Pause Procedure
This time you create a simple interactive procedure which displays a button control with a
prompt message: Click on OK or
Press Return to continue; this routine provides a pause which waits until
the user is ready to continue. This is added to the program from Lesson 1 so that the
heading remains on the screen (together with the prompt message) until the user presses a
key. This lesson introduces the procedure tree, which is fundamental to QA Builds operation and the use of controls.
Lesson 3: Creating a Table Update
Program
Describes a single-procedure program to update the EMPLOYEE table. Your program allows
insertion, deletion and modification of records. You are guided through the specification
of this program on a keystroke-by-keystroke basis. It introduces Table and Field
processing and validation of entered data.
Lesson 4: A Customer Table Update
Program
Shows you how to create an update program for the CUSTOMER table. Because the REGION table
is a parent of the CUSTOMER table, it introduces QA Builds
related table processing. In addition, we discuss complex screen layouts together with the
routines that arbitrate cursor movement, the auto-incrementing facility and
multiple-choice maps.
Lesson 5: Customer Number Enquiry
Program
You create an enquiry program for the CUSTOMER table. This program displays the CUSTOMER
fields when the correct CUSTOMER_NUMBER has been entered and does not allow update of the
database. Copying maps from another programs
mapset and use of local fields are among the features discussed.
Lesson 6: A Customer Name Enquiry
Program
Describes a CUSTOMER enquiry program similar to the previous one, but giving access by
customer name rather than number. The enquiry uses the Scan if no match search method and
INDEX_CUST_NAME, which is the secondary index of the CUSTOMER table.
Lesson 7: A Pop-up Menu Program
Shows you how to create a pop-up menu procedure giving options to run the customer number
and customer name enquiries, created in Lessons 6 and 7.
Lesson 8: Creating an Order Entry
Program
Describes an order entry program using two interactive procedures. The first of these gets
details of the order header and updates the ORDER_HEADER table. This is followed by a
procedure which uses the Window access mode to display a list of existing ORDER_LINE
records from which one may be selected for update. This program requires you to total the
order line value into the order value and perform stock validation and adjustment, as
order entry proceeds.
In these lessons you will create a number of new programs in the SALESORD database. We suggest that you name them MYPROG1 to MYPROG7. You will find a set of expert solutions already present, named PROG1 to PROG7. If you have difficulty with any of the exercises, load the corresponding expert solution into the Program Editor and examine how it was done.