Was this helpful?
Large Objects
Object Management Extension allows you to create data types that can accommodate objects that exceed the size limits for native data types. These objects are called large objects or peripheral objects. The name peripheral object indicates that these objects are stored outside of the table in which they are declared.
Large objects are stored as a number of segments, each of which is of some simple and small data type. This type is called the underlying data type for the large object. See Structure IIADD_DT_DFN Fields. Operations performed on large objects generally operate on a segment at a time.
Large objects can be up to two gigabytes in size. The code does not attempt to materialize the entire object in memory—rather, large objects are represented in memory using the II_PERIPHERAL data structure. The II_PERIPHERAL structure contains two fields. The first field is the tag and it contains the “style” of the large object. The style can be either real data or coupon. If the tag is seen by the Object Management Extension routines, the value indicates that the large object is a coupon. The coupon status indicates that only the information necessary to find and collect the object is present. At other times during the tag's life, it can contain different values, but these are not seen by the Object Management Extension code. (For example, the tag can have a variety of values that indicate how it is transmitted across the communication link.) The second field contains the length of the object. This field is an eight byte integer, although only four bytes are currently used (per_length1).
Large objects cannot be used as table keys, do not have histograms computed, and cannot be sorted. You must specify these restrictions as data type attributes along with the PERIPHERAL attribute at the time the data type is declared. See the dtd_attributes field in Structure IIADD_DT_DFN Fields.
Because of these restrictions, only a few of the required functions are necessary for peripheral objects. Only the length_check, getempty, tmlen, tmcvt, dbtoev, seglen, value_check, and xform routines must be provided. However, these attributes are independent from the peripheral attribute in the sense that the lack of histogram capability can be specified for non-peripheral objects. If so specified, the histogram routines need not be provided.
 
Last modified date: 01/30/2023