摘要:
An implementation of referential integrity in which descriptions of referential constraints are compiled into meta-data descriptions of the constraint rules and specifications. The meta-data descriptions of the constraints are stored in the form of objects called relationship descriptors. Each relationship descriptor contains a complete description of a referential constraint, either directly or by means of pointers to other objects such as record and index descriptors which contain information comprised in the constraint's specification. The relationship descriptors are linked into two types of chains by symbolic pointers. One type of relationship descriptor chain connects all relationship descriptors which have a common parent table. The other type of relationship descriptor chain connects relationship descriptors with common dependent tables. Both types of chains are anchored in respective fields in the tables' record descriptors. The use of meta-data descriptors facilitates both ready modification of the constraints, and speedy enforcement of the constraints by a single, shared procedure which may be embedded in the data base manager.
摘要:
A page-accessing method in a segmented tablespace 10 which eliminates unnecessary reading and locking. The tablespace comprises data pages 18 grouped into identically-sized segments 16, each segment storing data for a single table. A status indicator 26 for each data page of a segment is kept in a separate segment control block 20 stored on a space map page 14. Five data page status indicator values are maintained: (1) FULL (26a) - entirely full of current data; (2) PARTIALLY FULL (26b) - partially full of current data; (3) UNFORMATTED (26c) - empty; contains no data; (4) MASS DELETE (26d) - contains only obsolete data because of an unqualified deletion (mass delete) of data; or (5) QUALIFIED DELETE (26e) - contains only obsolete data because of a qualified deletion of data.When scanning over the data in a segment, UNFORMATTED and MASS DELETE pages are skipped. QUALIFIED DELETE pages are locked, and then skipped if they still contain only obsolete data when the lock is obtained. When inserting data into pages, preliminary reads of UNFORMATTED and MASS DELETE pages are avoided. Data integrity is ensured by placing integrity checking bits at the beginning and end of each page. If the bits contain the same value, the page's data integrity is intact. If the bits are different, the page's previous consistent contents are recovered from the log records.
摘要:
A method utilizing a coordinated pair of locking limits for managing concurrency and lock granularity tradeoff relations. A first limit is placed on the number of small granularity locks per resource. A second limit is placed on the number of locks assignable to each process. When the first number of small locks is reached, the method withdraws the small locks and grants only one lock to the entire resource (lock escalation). When a process requests an additional lock over the second limit, the lock is refused.
摘要:
A method for assuring atomicity of user requested multi-row update operations to tables such as in a relational database, guarantees that for any update operation that succeeds all stated effects will have occurred and that for any update operation that fails the system state as perceived by the user remains unchanged. This is accomplished by establishing, in response to a multi-row update operation request, an execution module of a program containing sets of machine language code instructions implementing the update operation request with a savepoint request at the beginning of the execution module of the program. For each set of machine language code instructions in or called by the execution module which modified the user perceived system state, information is logged to a soft log. Upon completing the execution module of the program, the savepoint is dropped, causing all soft log information recorded since the savepoint to be deleted and releasing all resources held to guarantee restoration of the user perceived system state at the time of the savepoint request. Responsive to the detection of an error during execution of the execution module of the program, the soft logged information is used to restore the user perceived state to that existing at the time of the savepoint request.
摘要:
A method and system for efficiently providing maintenance activity on a relational database that is utilized within a processing system is disclosed. The relational database includes a pool of threads and a plurality of resources. The pool of threads receive requests from a plurality of clients and control the plurality of resources. The method and system comprise determining that a maintenance activity is required and providing a first command that initiates a first process which terminates all threads in the pool of threads if the maintenance activity is required. The method and system further include providing a second command which initiates a second process after the maintenance activity has completed which causes the threads to be created and initiates the processing of requests. A system and method in accordance with the present invention based upon the determination that a maintenance activity is required causes the pool threads within a relational database to terminate and thus free up resources but also allows the connections from the clients to persist. Once the relational database resources are freed, the maintenance activity is performed, and thereafter distributed relational database processing is resumed.
摘要:
A method is disclosed for enforcing referential constraints on a record-by-record basis, immediately before or after each record is manipulated and while the record is still accessed, significantly improving the system's performance. Each record is visited only once to do both the constraint checking and the manipulation (insert/update/delete). If the constraint checking fails, then the entire relational operation of which the record manipulation is a part is backed out. For insertions, each record is first inserted 30, and then constraints respective the record are enforced 32,34. For updates, the record is updated 48 after constraints respecting the record's primary key are enforced 40,42, and before constraints respecting its foreign key(s) are enforced 44,46. Deletions are performed 52 before the constraints on the deleted record are enforced 54,56. Cascade deleted 58 are handled recursively 60. The method correctly processes cyclic constraints and self-referencing rows without special handling.