Browse Prior Art Database

A flexible and efficient layout for structured data in a relational database

IP.com Disclosure Number: IPCOM000013661D
Original Publication Date: 2001-Jul-12
Included in the Prior Art Database: 2003-Jun-18
Document File: 7 page(s) / 154K

Publishing Venue

IBM

Abstract

A flexible and efficient layout for structured data in a relational database Disclosed is a scheme to efficiently store and manipulate user defined structured data type objects in a Relational Database Management System (RDBMS). We begin this article by describing a typical application of this scheme. We go on to outline the specific design goals satisfied by this scheme and we end with a detailed description of the layout of structured data as mandated by the scheme. Typical Embodiment A typical embodiment of this invention is in a RDBMS (such as DB2 Universal Database) that implements the object relational features as specified in [SQL99Found] . In such a system it is possible to create new user defined structured data types by issuing Data Definition Language (DDL) statements, and use these types to create columns in tables. Further, it is possible to create subtypes of existing types these are new types that inherit all attributes of an existing type and possibly add new attributes. When a subtype is created based on an existing type, the existing type is called a supertype . It is necessary to support substitutability the property which allows an instance of a type to replace an instance of a supertype of the type. For the remainder of this article, we refer to an instance of a structured type interchangeably with the term Abstract Data Type , abbreviated to ADT.

This text was extracted from a PDF file.
At least one non-text object (such as an image or picture) has been suppressed.
This is the abbreviated version, containing approximately 27% of the total text.

Page 1 of 7

A flexible and efficient layout for structured data in a relational database

A flexible and efficient layout for structured data in a relational database

Disclosed is a scheme to efficiently store and manipulate user defined structured data type objects in a Relational Database Management System (RDBMS). We begin this article by describing a typical application of this scheme. We go on to outline the specific design goals satisfied by this scheme and we end with a detailed description of the layout of structured data as mandated by the scheme.

Typical Embodiment

*A typical embodiment of this invention is in a RDBMS (such as DB2 Universal Database) that implements the object relational features as specified in [SQL99Found]. In such a system it is possible to create new user defined structured data types by issuing Data Definition Language (DDL) statements, and use these types to create columns in tables. Further, it is possible to create subtypes of existing types - these are new types that inherit all attributes of an existing type and possibly add new attributes. When a subtype is created based on an existing type, the existing type is called a supertype. It is necessary to support substitutability - the property which allows an instance of a type to replace an instance of a supertype of the type. For the remainder of this article, we refer to an instance of a structured type interchangeably with the term Abstract Data Type , abbreviated to ADT.

Requirements and Design Objectives

A system such as that used for a typical embodiment of this invention as described above is required to support the queries of a language such as SQL [SQL99Found]. Typically, a query is compiled (a process of understanding the query), followed by the generation of an access plan, which in turn is used at runtime to actually perform operations, such as the following:

1. Creation of an instance of a user-defined structured type

2. Inserting an instance of a user-defined structured type into a column of a table

3. Retrieving/Observing attributes of an instance of a user-defined structured type

   4. Setting/Mutating attributes of an instance of a user-defined structured type To satisfy the four objectives above, we need to lay out user defined structured data in an efficient and flexible format in memory. The in-memory layout (henceforth referred to as runtime layout) needs to be of a form that can be easily converted to a datapage layout for the storage manager to handle in secondary storage. When the query itself is compiled, the space requirements of all data are estimated and used to allocate memory at runtime. This invention concerns itself only with the runtime layout of a structured type instance. The following design goals need to be satisfied:

1. Since substitutability is supported, the compile time space estimate of a structured data type instance may not be large enough. We need a way to dynamically support a larger

1

Page 2 of 7

instance than earli...