Creating Object and SQLJ Object Abstract Data Types

OBJECT and SQLJ OBJECT abstract data types allow you to specify attributes and procedures. In this example, we will create an Address object with Street, City, and ZipCode attributes.

  1. Open the property sheet of the abstract data type and select either OBJECT or SQLJ_OBJECT from the type list.
    The following additional tabs are displayed.
    • Attributes - lets you specify object (or SQLJ object) attributes with appropriate data types.
    • Procedures - lets you specify object (or SQLJ object) procedures with appropriate parameters.
  2. Click the Attributes tab and use the Add a Row tool to create appropriate attributes, specifying a Name, Code, Data Type, and, if appropriate, select the Mandatory (M) check box:


  3. Click the Procedures tab and use the Add a Row tool to create appropriate procedures, specifying a Name and Code, and, if appropriate, selecting the Final (F), Static (S) and/or Abstract (A) check boxes.
    An object abstract data type with a supertype can inherit non-final procedures. Use the Inherit Procedure tool to select a non-final procedure from a parent abstract data type.
  4. Click OK to return to your model.