Unlock instant, AI-driven research and patent intelligence for your innovation.

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

Active Publication Date: 2016-06-22
HUAWEI TECH CO LTD
View PDF4 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] After the application program accesses the shared memory, it needs to ensure that it can return to the original state. Otherwise, when the application program modifies the data in the shared memory abnormally, the shared data will be destroyed and the DBMS cannot be used. When the memory data is abnormal, the shared memory data will be destroyed, which greatly increases the complexity of the entire system, and the implementation cost is relatively high. At the same time, the introduction of logs also brings additional overhead.

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and device for accessing database and database management system
  • Method and device for accessing database and database management system
  • Method and device for accessing database and database management system

Examples

Experimental program
Comparison scheme
Effect test

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...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The embodiment of the invention provides a method and a device for accessing a database, and a data base management system. The method for accessing the database comprises the following steps: receiving data access requests initiated by business processes through an interface of a database management system DBMS client side database, wherein the client side database is used for providing a data access interface between the DBMS client side and a server, and the business processes are operated in the DBMS client side; and deciding whether the DBMS client side database or the DBMS server responds to the data access requests according to the type of the data access requests. As the DBMS client side database or the DBMS server can be decided to respond to the access requests according to the type of the access requests, the bottleneck problem that the access requests are all responded through the server is avoided; and the cost is low and the implementation is simple.

Description

technical field [0001] The embodiments of the present invention relate to data processing technologies, and in particular to a method and device for accessing a database and a database management system. Background technique [0002] Data access is a widely existing data processing requirement, usually an application program accesses data in a database. For example, data access may be implemented based on a database management system (Database Management System, DBMS). A DBMS generally includes a client and a server, and manages the database through a client / server (Client / Server, C / S) mode. [0003] The most common method for applications to access the database is that the client sends the application's request to the server through the communication channel, and the server processes the request sent by the client, performs operations such as query, read, and write on the database, and then sends the processing results through the communication channel. Return to the clie...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Patents(China)
IPC IPC(8): G06F17/30
Inventor 陈志标朱仲楚姚理
Owner HUAWEI TECH CO LTD