HP TurboIMAGE/iX Database Creation [ HP ALLBASE/4GL Developer Self-Paced Training Guide ] MPE/iX 5.0 Documentation
HP ALLBASE/4GL Developer Self-Paced Training Guide
HP TurboIMAGE/iX Database Creation
The following paragraphs describe the procedure to define the HP
TurboIMAGE/iX database for the training application.
The first step is to define the database. Run HP TurboIMAGE DBSCHEMA
using the following database definition.
BEGIN DATA BASE TRAIN, LANGUAGE:AMERICAN;
PASSWORDS: 10 DEVELOP;
ITEMS:
SUPPLIER-NO, I1 (/10);
PRODUCT-NO, X6 (/10);
DESCRIPTION, X30 (/10);
LEAD-TIME, I1 (/10);
ORDER-NO, I1 (/10);
OFFICER-NAME, X30 (/10);
QUANTITY, I1 (/10);
UNIT-MEASURE, X4 (/10);
COST, P12 (/10);
ORDER-DATE, X8 (/10);
DELIVERY-DATE, X8 (/10);
OPTION-KEY, X10 (/10);
OPTION-NO, X4 (/10);
SETS:
NAME: PRODUCT, MANUAL (/10);
ENTRY: PRODUCT-NO (2),
DESCRIPTION,
SUPPLIER-NO,
LEAD-TIME;
CAPACITY: 211;
NAME: OPTION-KEY, AUTOMATIC (/10);
ENTRY: OPTION-KEY (1);
CAPACITY: 211;
NAME: OFFICERS, AUTOMATIC (/10);
ENTRY: OFFICER-NAME (1);
CAPACITY: 211;
NAME: ORDER-NO, AUTOMATIC (/10);
ENTRY: ORDER-NO (1);
CAPACITY: 211;
NAME: ODATE, AUTOMATIC (/10);
ENTRY: ORDER-DATE (1);
CAPACITY: 211;
NAME: DDATE, AUTOMATIC (/10);
ENTRY: DELIVERY-DATE (1);
CAPACITY: 211;
NAME: ORDER, DETAIL (/10);
ENTRY: ORDER-NO (ORDER-NO),
OFFICER-NAME (OFFICERS),
PRODUCT-NO (!PRODUCT),
QUANTITY,
UNIT-MEASURE,
COST,
ORDER-DATE (ODATE),
DELIVERY-DATE (DDATE);
CAPACITY: 200;
NAME: OPTION, DETAIL (/10);
ENTRY: OPTION-KEY (OPTION-KEY),
PRODUCT-NO (!PRODUCT),
OPTION-NO,
DESCRIPTION,
COST,
QUANTITY,
UNIT-MEASURE; CAPACITY: 200;
END.
Then create the database, using HP TurboIMAGE DBUTIL. For more
information about creating the database, refer to the HP TurboIMAGE/iX
Database Management System Reference Manual.
Once you have created the database, you must define it within the HP
ALLBASE/4GL administrator application.
Defining the Database
The following paragraphs describe the procedure for defining the database
within HP ALLBASE/4GL. This screen allows you to specify the name, group,
and account of the HP TurboIMAGE/iX database and allocate an HP
ALLBASE/4GL name for the database.
Database Definition Screen
To enter the field values:
Complete the database definition screen using the following information.
Field Entry Explanation
---------------------------------------------------------------------------------------
Database Name traindb This is the name of the database as it will
be known within HP ALLBASE/4GL.
Database Type Accept the default This field indicates the type of database
value of T. that you are defining. Currently, you can
only define HP TurboIMAGE/iX databases.
When you commit this field, an HP
TurboIMAGE/iX window is displayed.
Description Enter a description
of the database in
this field.
External Name Enter TRAIN
HP TurboIMAGE/iX Window
If the database is not in the account and group identified by the
HP4TIPATH system variable, you should enter the fully qualified name of
the database root file in this field (that is, including the group and
account in the name).
To complete the entries:
1. Press the Commit Data function key to complete this screen.
Your next step is to give the training application access to this
database.
The Parameters for Database Access Screen
Go to the parameters for database access screen to give the training
application access to the traindb database.
Parameters for Database Access
To enter the field values:
Field Entry Explanation
---------------------------------------------------------------------------------------
Application training This is the name of the application to
which you wish to allow database access.
Database Name traindb This is the name of the HP TurboIMAGE/iX
database. When you commit this field, a
password window is displayed.
Action Accept the default
action of Add (A).
Password DEVELOP
Password Window
This HP TurboIMAGE/iX database password supplies all developers and users
of the training application with write access to all parts of the
database.
To complete the entries:
1. Press the Commit Data function key to complete this screen.
You have now completed the application definition and database definition
required for developers to begin developing the training application.
MPE/iX 5.0 Documentation