发明名称 Implementing a multi-column/multi-row constraint in a relational database table
摘要 A method, system, and computer program product for implementing a multi-column/multi-row constraint. Lock techniques prevent access collisions even when two or more concurrently running software applications are attempting to insert rows into the same relational database table (subject to the same multi-column/multi-row constraints). The method commences by receiving (e.g., from a first process) a first row to be inserted into a relational database table where the row comprises at least two constrained columns corresponding to the multi-column/multi-row constraint, then receiving (e.g., from a second process) a second row to be inserted into the same table. Using column locks, the method recognizes the potential for conflicting row insertions, and manages locks to prevent conflicting access grants to the two constrained columns of the existing database table. The evaluation of the multi-column/multi-row constraint is performed over the first row to be inserted and a row or rows of the relational database table.
申请公布号 US9384228(B2) 申请公布日期 2016.07.05
申请号 US201313782964 申请日期 2013.03.01
申请人 Oracle International Corporation 发明人 Zhang Zhihai;Xie Qingyun;Ravada Siva
分类号 G06F7/00;G06F17/00;G06F17/30 主分类号 G06F7/00
代理机构 Vista IP Law Group, LLP 代理人 Vista IP Law Group, LLP
主权项 1. A computer implemented method for implementing a multi-column/multi-row constraint when two or more concurrently running transactions are inserting rows into one relational database table, the method comprising: receiving a first row to be inserted into the one relational database table for a first transaction of the two or more concurrently running transactions, the first row having first values in at least two constrained columns corresponding to the multi-column/multi-row constraint, wherein the multi-column/multi-row constraint operates concurrently on multiple columns and multiple rows in the one relational database table; receiving a second row to be inserted into the one relational database table for a second transaction of the two or more concurrently running transactions, the second row having second values in the at least two constrained columns corresponding to the multi-column/multi-row constraint; preventing conflicting access grants to the at least two constrained columns of the one relational database table by evaluating the first values and the second values, wherein preventing the conflicting access grants comprises using a column lock to lock one or more columns of the at least two constrained columns with a specified column value; evaluating the multi-column/multi-row constraint using at least one of the first row and the second row to be inserted and at least one row of the one relational database table; and inserting the first row and/or second row into the one relational database table when the multi-column/multi-row is satisfied.
地址 Redwood Shores CA US