Patent ID: 7461065

Claim:
A method for performing at least one transaction on at least one column of a table in a database system, the method comprising: determining whether a first transaction of the at least one transaction fulfills all of at least one criteria, wherein the at least one criteria includes the at least one transaction being an addition or a subtraction on at least one value only for the at least one column, the at least one transaction operating on data in a specified column for which a shared numeric lock is used, and the at least one transaction not modifying data in other columns that are not candidates for a shared numeric lock; ensuring that the at least one column is in a shared numeric lock if the first transaction fulfills all of the at least one criteria, wherein the shared numeric lock is a lock the allows at least a second transaction fulfilling all of the at least one criteria to access the same column concurrently with the first transaction without releasing the shared numeric lock between transactions, and wherein the shared numeric lock is released only after all of the transactions fulfilling all of the criteria have completed processing; and processing the first transaction, wherein processing the first transaction comprises: adding the first transaction to a set of concurrent transactions if the shared numeric lock already exists for the column, adding the first transaction including creating a shared numeric lock data structure for the first transaction; creating the shared numeric lock if the shared numeric lock does not already exist for the column, creating the shared numeric lock including creating the shared numeric lock data structure for the first transaction; obtaining a row lock for the row corresponding to the first transaction; tracking data relating to the first transaction, wherein the data includes a table number, a row number, a column number, a row lock, a current committed value of a measure of the first transaction and a concurrent transaction count indicating a number of transactions sharing the shared numeric lock; and managing a commit for the first transaction, wherein the managing the commit comprises: obtaining the shared numeric lock data structure for the first transaction; updating a current committed value for the first transaction; writing the current committed value for the first transaction; decrementing a concurrent transaction count indicating a number of the at least one of transaction using the shared numeric lock; and if the transaction count is zero after the decrementing, releasing the shared numeric lock.