Home page  
Help >
The Application Interface
Version 7.11
The Application Interface
The Application Interface

The Application Interface (AI) establishes a view of the data base. The view can encompass the entire data base or be very restrictive.
There can be multiple AIs for a given data base.

The name of the compiled Application Interface (the .pi file), with or without the .pi extension, is the parameter that is passed to the
ddlOpen() function to open a database.

The ddlCompileDBD() function creates a default AI (called the General Interface, or GI) that has the same name as the database
(from the .dbd Data Base Name Is statement). Thus, in the default case, the user supplies the Data Base Name, which in this case is
identical to the .pi name, to the ddlOpen() function.

1.2 Custom Application Interface

A custom AI is used primarily to create one or more Record Descriptions. It can also be used to create additional collections;
or to eliminate one or more of the default collections; however, this usage is rare.

A custom AI can be created either to override the default AI; and/or to provide additional AIs for special purposes.

The name of an AI (i.e., the name of the compiled .pi file) is taken from the name of the AI source file, plus the .pi extension.
When the default AI is to be replaced with a custom AI, it is advisable to invoke the SUPPRESS GI statement in the .dbd
in order to prevent confusion.

For example, to replace the default AI,
   . If the .dbd is:
      TestDirt.dbd
         Data Base Name Is TestDirt
         Suppress GI
         etc
 
   . Then the AI would be:
      TestDirt.txt
         Data Base Name Is TestDirt
         etc

To create additional AIs named Executive, Sales and Producion,
      Executive.txt
         Data Base Name Is TestDirt
         etc
 
      Sales.txt
         Data Base Name Is TestDirt
         etc
 
      Production.txt
         Data Base Name Is TestDirt
         etc

An AI definition is created as a symbolic source file using an ASCII text editor. The naming convention for the source file is described above.
The symbolic source file is then compiled with the ddlCompileAI() function; this produces the object .pi file.

1.3 The Application Interface Language
 
   1.3.1 The DATA BASE NAME IS statement
 
      Syntax: DATA BASE NAME IS  <data-base-name>
 
      Description: This must be the first statement in any AI text file. The <data-base-name>
         can be a full path name, but the name must agree with the name used in the Data Base 
         Definition's DATA BASE NAME IS statement.
         The data base name provides the link from the AI to the data base.
 
   1.3.2 The EXTRA COLLECTIONS statement
 
      Syntax: EXTRA COLLECTIONS ARE  <collection-name> [... <collection-name>]
 
      Description: This is an optional statement used to add new collection names
         or to delete default collection names.
 
         The default collection names are A, B, C, D, E, U and V. To delete one of these, put a 
         minus sign in front of the name. To add collection names, add it to this list. For example:
 
            EXTRA COLLECTIONS ARE -E  SHIPS 
 
               This statement removes E as a legitimate collection name and adds the word SHIPS
               as a legitimate collection name. 
 
   1.3.3 Record Descriptions
 
      The description of the Record Description Definition Language is contained in the 
      Record Description document.
 
      An example of a symbolic Record Description.

Copyright © 2019 , WhamTech, Inc.  All rights reserved. This document is provided for information purposes only and the contents hereof are subject to change without notice. Names may be trademarks of their respective owners.