Conventional database servers receive transactions from user terminals. Upon receipt of a transaction, the database server carries out various processes; for example, it adds, reads out, updates, and deletes data. If this type of database server concurrently receives transactions that attempt to update the same data from a plurality of users, the database server performs exclusive control, such as a lock method etc., on various processes to assure the integrity of the data.
Specifically, to assure data integrity, the database server exclusively controls transactions that attempt to update the same data with conflicting transactions. For example, the database server uses pessimistic lock, optimistic lock, or another type of exclusive control etc.
Pessimistic lock is a method that assumes that transactions attempting to update data in a database are highly likely to be received at the same time from a plurality of users. Once a transaction reads out data to be updated, the other transactions are excluded.
Optimistic lock is a method that assumes that transactions attempting to update data in a database are less likely to be received at the same time from a plurality of users. Once a transaction reads out data to be updated, if another transaction attempts to update and commit the data before the transaction completes the update of the data, the other transaction is treated to be invalid.
As described above, to assure data integrity, a database server uses pessimistic lock, optimistic lock, or another type of exclusive control to process conflicting transactions in succession while excluding the other transactions.
Technology that enables a database server to process a plurality of transactions together is also disclosed. For example, the database server combines transactions entered in a certain period of time and recombines the transactions for each data to be read out and updated by transactions to determine their execution order, before the database server executes the transactions.
However, the above conventional technology is problematic in that conflicting transactions cannot be executed at the same time. For example, a database server that uses exclusive control executes conflicting transactions in succession to assure data integrity, so the database server cannot execute the conflicting transactions at the same time.
In the method in which a plurality of transactions are processed together, if the database server executes a transaction that determines a branch instruction, for example, the database server determines a condition from a result obtained by searching the transaction for data before executing a next process, so the database server cannot send all processes executed in the transaction to a database in advance. It is difficult and is not practical to consider, during the design of an application, updates carried out by other transaction to be executed at the same time and design execution of the transactions.
Japanese Laid-open Patent Publication No. 2009-271665 is an example of related art.