Method and device for accessing database and database management system
A technology for managing systems and databases, applied in electrical digital data processing, special data processing applications, instruments, etc., can solve the problems of high implementation cost, destruction of shared data, and inability to use DBMS, so as to improve performance, reduce overhead, and ensure data. The effect of consistency
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0061] figure 1 It is a flowchart of a method for accessing a database provided by Embodiment 1 of the present invention. The method of this embodiment is applicable to a database management system (DatabaseManagementSystem, DBMS) including a client library and a server, such as figure 2 As shown, DBMS includes server (DBMSServer), client library (DBclientlib) and shared memory (sharememory); where: DBMSServer is an entity that provides data read and write services for applications, and DBMS client library (DBclientlib) provides data access Interface and read-only query service entity, shared memory is used to store all configuration data (Configdata), control data (Controldata), data table (Table) and index data (indexdata) of DBMS, and other shared data. In the method for accessing the database provided by the embodiment of the present invention, the business process can access the data in the DBMS through the interface provided by DBclientlib. For the data query request (...
Embodiment 2
[0072] image 3 It is a flow chart of the method for accessing the database provided by Embodiment 2 of the present invention. On the basis of the technical solutions of the above embodiments, further optimization is carried out. refer to image 3 According to the type of the data access request, the embodiment of the present invention determines that the client library of the DBMS responds to the data access request or the operation of responding to the data access request by the server of the DBMS specifically includes the following steps:
[0073] Step 121, if the data access request is a data read request requesting to read the first data, generate an execution plan corresponding to the data read request, store it in the shared memory, and store the execution plan in the shared memory The location information is sent to the client library, so that the client library directly accesses the shared memory according to the location information, so as to obtain the first data ...
Embodiment 3
[0080] Figure 4 It is a flow chart of the method for accessing the database provided by the third embodiment of the present invention. The embodiment of the present invention is based on the above-mentioned embodiments and further optimized. Refer to Figure 4 , in this embodiment, if the type of the data access request is a read request, generate a corresponding execution plan in the shared memory, and return the location of the execution plan in the shared memory to the client library, through the The above-mentioned client library accesses the shared memory to read data and specifically includes the following steps:
[0081] Step 310, if the type of the data access request is a read request, check whether the shared memory is mapped to the business process space of the business process according to the data access request, if yes, perform step 320, if not, perform step 310 330.
[0082] In the above steps, the shared memory can be mapped to the business process space whe...
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 