A method, apparatus, device and storage medium for data query

By analyzing the query characteristics of business data in real time and dynamically selecting the appropriate index mode, the problem of low query efficiency in multi-scenario data queries is solved, realizing the flexibility and efficiency of data queries.

CN114547034BActive Publication Date: 2026-04-14NEUSOFT CORP
View PDF 4 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
NEUSOFT CORP
Filing Date
2022-02-23
Publication Date
2026-04-14

AI Technical Summary

Technical Problem

Existing large-scale data management systems suffer from low query efficiency and cannot meet the needs of multi-dimensional data queries due to the lack of flexible indexing mechanisms when querying data in multiple scenarios.

Method used

By analyzing the query characteristics of business data in real time, the system dynamically selects the appropriate index mode and chooses the most suitable index mode from multiple index modes for query operations, including multi-level hierarchical indexes, global distributed indexes, and indexes based on linear technology.

Benefits of technology

It achieves flexibility and efficiency in data querying, avoids the query limitations caused by a single indexing strategy, and improves the scalability and performance of data querying.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114547034B_ABST
    Figure CN114547034B_ABST
Patent Text Reader

Abstract

The application provides a data query method, device, equipment and storage medium. The method comprises the following steps: analyzing current query characteristics of business data in real time; selecting an adaptive index mode from a plurality of configured index modes according to the current query characteristics; and performing a query operation of the business data by using the adaptive index mode. The application realizes dynamic conversion of an index mode used in data query, guarantees adaptability between data index and query requirements, avoids the problem of data query limitations when a single fixed index strategy is used, thereby ensuring flexibility of data query, increasing scalability of data query, and improving efficiency of data query.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of data processing technology, specifically to a method, apparatus, device, and storage medium for data querying. Background Technology

[0002] With the deepening application of big data technology, real-time querying and analysis of data across multiple scenarios presents new challenges to high-speed and accurate data retrieval. The explosive growth in data volume has brought enormous challenges to traditional relational databases, causing them to encounter bottlenecks in areas such as data query scalability and fault tolerance.

[0003] Currently, existing large-scale data management systems typically only support fast queries based on primary keys when performing corresponding data query operations. Due to the lack of indexes, views, and other mechanisms, they cannot provide efficient multi-dimensional data queries. In this case, existing data queries usually employ a single, fixed indexing strategy. However, given the complex and diverse data storage methods in multi-scenario big data environments, a single, fixed indexing strategy has certain limitations in data querying, significantly impacting query efficiency. Summary of the Invention

[0004] This application provides a method, apparatus, device, and storage medium for data querying, ensuring the flexibility, scalability, and efficiency of data querying.

[0005] In a first aspect, embodiments of this application provide a data query method, the method comprising:

[0006] Real-time analysis of current query characteristics of business data;

[0007] Based on the current query characteristics, select the appropriate index mode from the configured multi-index modes;

[0008] The business data query operation is performed using the adapted index pattern.

[0009] Secondly, embodiments of this application provide a data query apparatus, the apparatus comprising:

[0010] The feature analysis module is used to analyze the current query features of business data in real time.

[0011] The pattern adaptation module is used to select the appropriate index pattern from the configured multi-index patterns based on the current query characteristics.

[0012] The data query module is used to perform query operations on the business data using the adapted index mode.

[0013] Thirdly, embodiments of this application provide an electronic device, which includes:

[0014] A processor and a memory, the memory being used to store a computer program, and the processor being used to invoke and run the computer program stored in the memory to perform the data query method provided in the first aspect of this application.

[0015] Fourthly, embodiments of this application provide a computer-readable storage medium for storing a computer program that causes a computer to perform a data query method as provided in the first aspect of this application.

[0016] Fifthly, embodiments of this application provide a computer program product, including a computer program / instructions, characterized in that, when the computer program / instructions are executed by a processor, they implement the data query method provided in the first aspect of this application.

[0017] This application provides a data query method, apparatus, device, and storage medium that analyzes the current query characteristics of business data in real time to select an appropriate index mode from a set of configured index modes. The appropriate index mode is then used to execute the business data query operation, thereby achieving dynamic changes in the index mode used during data query. This ensures the adaptability between the data index and query requirements, avoids the limitations of data querying when using a single, fixed indexing strategy, and thus ensures the flexibility, scalability, and efficiency of data querying. Attached Figure Description

[0018] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0019] Figure 1 This is a flowchart illustrating a data query method according to an embodiment of this application;

[0020] Figure 2 This is a schematic diagram of the system used in the data query method shown in the embodiments of this application;

[0021] Figure 3 A flowchart illustrating another data query method as shown in an embodiment of this application;

[0022] Figure 4 This is a schematic block diagram illustrating a data query device according to an embodiment of this application;

[0023] Figure 5 This is a schematic block diagram of the electronic device provided in the embodiments of this application. Detailed Implementation

[0024] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0025] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or server that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or devices.

[0026] For real-time queries of business data across multiple scenarios, a pre-defined, fixed indexing strategy is typically used within the business system. This approach has limitations in data querying and restricts high-speed, accurate queries of business data across various scenarios. Therefore, considering the diverse data query characteristics across different business scenarios, various indexing patterns exist, such as multi-level hierarchical indexing, globally distributed indexing, and linear indexing. To address these technical issues, this application designs a method for dynamically selecting indexing patterns for multi-scenario data queries. By dynamically selecting the appropriate indexing pattern from the configured multiple indexing patterns each time business data is queried, the corresponding data query operation is executed. This achieves dynamic changes in the indexing pattern used during data queries, ensuring the adaptability between the data index and query requirements, and guaranteeing flexible and efficient data queries.

[0027] First, for data queries in multi-scenario business systems, this application allows for the pre-configuration of multiple existing index modes in the business system to support the dynamic selection of the index mode actually used when querying business data in real time.

[0028] Currently, representative data indexing technologies mainly include: multi-level hierarchical indexing, globally distributed indexing, and linear indexing. These three technologies are used to illustrate the multi-indexing mode in this application. It should be noted that the multi-indexing mode in this application includes, but is not limited to, the three indexing technologies mentioned above. The multi-indexing mode configured in the business system can be any existing indexing technology.

[0029] 1) Multi-level hierarchical indexing technology

[0030] Multi-level hierarchical indexing technology comprises local and global indexes, utilizing a large cluster of inexpensive computers to provide users with computing and storage resources. User data is divided into data blocks according to certain rules and distributed to different computer nodes for storage according to the protocol of a distributed file system. In a two-level indexing scheme, a local index is created for the data on each computer node, and this local index is only responsible for the data on that local node. In addition to the local index, each computing node also needs to share a portion of storage space to store the global index. The global index is composed of some local indexes. Due to storage space limitations and query efficiency requirements, it is impossible to publish all local index nodes to the global index. Therefore, a subset of index nodes needs to be selected for publication according to certain rules. For the selected index nodes, different schemes can be used to organize them within the global index.

[0031] 2) Global Distributed Indexing Technology

[0032] To support large-scale data storage and ensure high throughput for business systems, a fault-tolerant, highly scalable distributed multi-way search tree data structure (B-tree structure) with a globally distributed indexing technique is proposed. This technique, in addition to the general characteristics of traditional B-trees, also features new characteristics: automatic load balancing, atomicity of operations, and dynamic addition or deletion of storage nodes. All data is organized in a B-tree structure, with B-tree nodes (including internal nodes and leaf nodes) distributed across different nodes. To ensure data consistency, a version table is introduced to record the latest version of each node. To improve query efficiency, internal nodes of the B-tree are cached on the client and updated using lazy replication. This method has two main drawbacks: first, it is highly efficient for simple point queries but less efficient for complex range queries and multidimensional queries; second, the server-side maintenance cost is high, and the client needs to consume a significant amount of memory to cache the internal nodes of the B-tree.

[0033] 3) High-efficiency data indexing technology based on linear techniques

[0034] Efficient data indexing techniques based on linearization are specific index structures, such as B-tree structures or R-tree structures that evolve towards multi-dimensional spaces. When business data within a business system is updated very frequently, the cost of index update and maintenance becomes extremely high. Therefore, to reduce the cost of index update and maintenance while ensuring system performance, indexing schemes based on linearization techniques have been proposed. The basic idea is to divide the entire spatial range into equal-sized grids according to certain rules, assign a number to each grid, and use these numbers to generate a set of representative numbers for the spatial target. Essentially, it maps entities in k-dimensional space to one-dimensional space in a specific way, thereby utilizing the relatively mature one-dimensional indexing techniques in existing database management systems to organize data.

[0035] As can be seen from the above, each existing indexing model has its own advantages and disadvantages. For example, globally distributed indexing technology can support large-scale business data storage and ensure high throughput of business systems, while efficient data indexing technology based on linear techniques can reduce the maintenance cost of data indexes when business data is frequently updated.

[0036] To ensure the compatibility between data indexes and query requirements, and to improve the flexibility and efficiency of data queries, this application provides a detailed explanation of how to dynamically switch to the appropriate index mode to execute the actual data query operation for each data query.

[0037] Figure 1 This is a flowchart illustrating a data query method according to an embodiment of this application. (Refer to...) Figure 1 The method may specifically include the following steps:

[0038] S110 analyzes the current query characteristics of business data in real time.

[0039] The primary objective of this application is to dynamically select the appropriate index pattern for each data query executed within the business system, thereby improving the flexibility, efficiency, and accuracy of data queries. Furthermore, existing indexing technologies (i.e., the various index patterns in this application) each have their own advantages and disadvantages, and are all related to the data change characteristics within the business system. For example, globally distributed indexes can support large-scale data storage and high throughput, while efficient data indexing technologies based on linear techniques can reduce the index maintenance cost of business data when data is frequently updated. Therefore, to accurately select the most suitable index pattern for each data query, upon receiving each data query request, it is necessary to first retrieve various business data within the current and historical time periods from the business system, and then analyze the current query characteristics of the business data in real time based on the changes in the business data queries.

[0040] It should be noted that, in order to match the advantages of existing index patterns, the current query characteristics in this application can include at least three types: data query update time, data throughput, and query response time. This is so that it can be determined which index pattern's advantages the current query characteristics specifically match, thereby selecting the most suitable index pattern to execute the actual query operation.

[0041] S120: Based on the current query characteristics, select the appropriate index mode from the configured multi-index modes.

[0042] In this application, in order to realize the dynamic change of the index mode used during data query and ensure the adaptability between data index and query requirements, various existing indexing technologies will be pre-configured in the business system to obtain a pre-configured multi-index mode, so that the most suitable index mode can be quickly selected from the multi-index mode for each subsequent data query.

[0043] Therefore, after analyzing the current query characteristics of the business data, the first step is to analyze the query performance advantages of each index mode within the pre-configured multi-index modes. Then, feature matching is performed between the current query characteristics and the query performance advantages of each index mode to determine which index mode's query performance advantage the current query characteristics specifically meet. Furthermore, based on the compliance of the current query characteristics with the query performance advantages of each index mode, the most suitable index mode for this query is selected from the pre-configured multi-index modes and used as the appropriate index mode in this application.

[0044] It should be noted that, as Figure 2As shown, this application, based on the original data query scheme, allows for the pre-configuration of multiple existing index patterns within the business system, such as multi-level hierarchical indexing, globally distributed indexing, and efficient data indexing based on linear techniques. Furthermore, to enable dynamic changes in the index pattern used during data queries, a corresponding functional module for intelligent index pattern recognition will be added to the business system. This module primarily connects to the business data source within the business system and analyzes the current query characteristics of the business data in real time to dynamically select the appropriate index pattern.

[0045] S130 executes business data query operations using the adaptive index mode.

[0046] After selecting the appropriate index pattern from multiple index patterns, the appropriate index pattern is run directly within the business system. This allows the actual query operation of the business data to be performed using the appropriate index pattern. In order to ensure the flexibility of data query and improve the efficiency of data query in multiple scenarios by dynamically changing the actual index pattern used.

[0047] In addition, to ensure fast data retrieval, such as Figure 2 As shown, after selecting the appropriate index mode from the configured multi-index modes, this application also performs route update and load balancing configuration on the appropriate index mode. By performing route update and load balancing operations on data retrieval and storage within the computing cluster used for data query, the query performance after the data index mode is dynamically changed is guaranteed.

[0048] The technical solution provided in this application analyzes the current query characteristics of business data in real time to select an appropriate index mode from the configured multi-index modes, and then uses the appropriate index mode to execute the query operation of business data. This achieves dynamic transformation of the index mode used during data query, ensuring the adaptability between the data index and the query requirements, avoiding the data query limitations that exist when using a single fixed index strategy, thereby ensuring the flexibility of data query, increasing the scalability of data query, and improving the efficiency of data query.

[0049] As an optional implementation scheme in the embodiments of this application, in order to ensure flexible transformation of the adaptive index mode, this application provides a detailed description of the specific selection process of the adaptive index mode and the actual query process.

[0050] Figure 3 This is a flowchart illustrating another data query method as shown in an embodiment of this application. Figure 3 As shown, the method may specifically include the following steps:

[0051] S310 analyzes the current query characteristics of business data in real time.

[0052] S320, determine the query metrics for each index pattern within the configured multi-index pattern.

[0053] Optionally, to ensure the accuracy of index pattern adaptation, this application analyzes the query performance advantages of each index pattern within the configured multi-index pattern for data retrieval. Then, based on the query performance advantages of each index pattern, a corresponding query metric is set for each index pattern. This query metric represents the upper limit of query performance supported by that index pattern. When the performance characteristics of the current query executed in the business system are lower than the query metric of a certain index pattern, it is necessary to use that index pattern to execute the corresponding query operation to improve the corresponding query performance advantage and ensure the efficiency of data retrieval.

[0054] For example, for an index pattern represented by a multi-level hierarchical indexing technique, the query metric can be set to the upper limit γ of the data query efficiency metric within the business system; for an index pattern represented by a globally distributed indexing technique, the query metric can be set to the upper limit β of the data throughput within the business system; and for an index pattern represented by an efficient data indexing technique based on linear technology, the query metric can be set to the upper limit α of the data query update frequency within the business system.

[0055] S330: Match the current query features with the query metrics of each index pattern to determine the corresponding suitable index pattern.

[0056] In this application, the current query characteristics of the business data are matched sequentially with the query metrics of each index mode to determine whether the current query characteristics are lower than the query metrics of each index mode. This analysis is used to determine which index mode's query performance advantage needs to be improved within the business system for this data query, thereby identifying the corresponding suitable index mode.

[0057] For example, if the index update frequency, represented by the data index update time within the current query feature, is greater than the pre-set upper limit α for data query update frequency, it indicates that the data index within the business system is frequently updated, which may affect the data index query efficiency. Therefore, an efficient data indexing technology based on linear technology will be automatically selected as the appropriate indexing mode in this application to reduce the index maintenance cost when data is frequently updated. If the data throughput within the current query feature is greater than the pre-set upper limit β for data throughput, it indicates that the data query throughput performance requirements within the business system are high. Therefore, the corresponding globally distributed indexing technology needs to be automatically selected as the appropriate indexing mode in this application to perform data queries, ensuring that the business system has high throughput. If the data query efficiency, represented by the query response time within the current query feature, is greater than the known upper limit γ for data query efficiency, a multi-level hierarchical index will be automatically selected as the appropriate indexing mode in this application to improve the efficiency of data queries.

[0058] In this application, the query metrics for each index mode are fixed experimental constants set according to the business needs of specific business scenarios.

[0059] It should be noted that, considering the current query characteristics in this application may successfully match the query metrics of multiple index patterns, it is necessary to select the most suitable index pattern from the successfully matched index patterns. Therefore, this application will pre-set the corresponding priorities for multiple index patterns according to their advantages and disadvantages. If the current query characteristics successfully match the query metrics of at least two index patterns, the appropriate matching index pattern will be determined based on the priority of each index pattern. In other words, after the current query characteristics of the business data successfully match the novelty search metrics of multiple index patterns, the index pattern with the highest priority can be selected from the successfully matched index patterns as the appropriate matching index pattern in this application.

[0060] S340: Switch the current index mode to the adaptive index mode and run the adaptive index mode to complete the query operation of business data.

[0061] Once the appropriate index mode is determined, the current index mode is switched to the appropriate index mode directly within the business system, and then the appropriate index mode is run to perform the actual query operation of the business data.

[0062] The technical solution provided in this application analyzes the current query characteristics of business data in real time to select an appropriate index mode from the configured multi-index modes, and then uses the appropriate index mode to execute the query operation of business data. This achieves dynamic transformation of the index mode used during data query, ensuring the adaptability between the data index and the query requirements, avoiding the data query limitations that exist when using a single fixed index strategy, thereby ensuring the flexibility of data query, increasing the scalability of data query, and improving the efficiency of data query.

[0063] Figure 4 This is a schematic block diagram illustrating a data query device according to an embodiment of this application. Figure 4 As shown, the device 400 may include:

[0064] Feature analysis module 410 is used to analyze the current query features of business data in real time;

[0065] The pattern adaptation module 420 is used to select an appropriate index pattern from the configured multi-index patterns based on the current query characteristics.

[0066] The data query module 430 is used to perform query operations on the business data using the adapted index mode.

[0067] Furthermore, the mode adaptation module 420 may include:

[0068] The metric determination unit is used to determine the query metrics for each index pattern within the configured multi-index pattern.

[0069] The pattern adaptation unit is used to match the current query features with the query indicators of each index pattern to determine the corresponding adapted index pattern.

[0070] Furthermore, the corresponding mode adaptation unit can be specifically used for:

[0071] If the current query feature matches the query metrics of at least two index patterns, the corresponding suitable index pattern is determined according to the priority of each index pattern.

[0072] Furthermore, the data query module 430 can be specifically used for:

[0073] Switch the current index mode to the adapted index mode and run the adapted index mode to complete the query operation of the business data.

[0074] Furthermore, the data query device 400 may also include:

[0075] The index configuration module is used to perform route updates and load balancing configurations for the adapted index mode.

[0076] Furthermore, the current query characteristics of the business data include at least the data query update time, data throughput, and query response time.

[0077] In this embodiment, by analyzing the current query characteristics of business data in real time, an appropriate index mode is selected from the configured multi-index modes. Then, the appropriate index mode is used to execute the query operation of business data, thereby realizing the dynamic change of the index mode used during data query, ensuring the adaptability between data index and query requirements, avoiding the problem of data query limitations when using a single fixed index strategy, thus ensuring the flexibility of data query, increasing the scalability of data query, and improving the efficiency of data query.

[0078] It should be understood that the device embodiments and method embodiments can correspond to each other, and similar descriptions can be referred to the method embodiments. To avoid repetition, further details will not be provided here. Specifically, Figure 4 The apparatus 400 shown can execute any of the method embodiments provided in this application, and the foregoing and other operations and / or functions of each module in the apparatus 400 are respectively for implementing the corresponding processes in the various methods of the embodiments of this application. For the sake of brevity, they will not be described in detail here.

[0079] The apparatus 400 of this application embodiment has been described above from the perspective of functional modules in conjunction with the accompanying drawings. It should be understood that this functional module can be implemented in hardware, in software instructions, or in a combination of hardware and software modules. Specifically, the steps of the method embodiments in this application can be completed by integrated logic circuits in the processor's hardware and / or by software instructions. The steps of the method disclosed in this application embodiment can be directly embodied as being executed by a hardware decoding processor, or by a combination of hardware and software modules in the decoding processor. Optionally, the software module can be located in a mature storage medium in the art, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, etc. This storage medium is located in memory, and the processor reads information from the memory and, in conjunction with its hardware, completes the steps in the above method embodiments.

[0080] Figure 5 This is a schematic block diagram of the electronic device 500 provided in the embodiments of this application.

[0081] like Figure 5 As shown, the electronic device 500 may include:

[0082] The system includes a memory 510 and a processor 520. The memory 510 stores computer programs and transfers the program code to the processor 520. In other words, the processor 520 can retrieve and run the computer program from the memory 510 to implement the methods described in the embodiments of this application.

[0083] For example, the processor 520 can be used to execute the above-described method embodiments according to instructions in the computer program.

[0084] In some embodiments of this application, the processor 520 may include, but is not limited to:

[0085] General-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.

[0086] In some embodiments of this application, the memory 510 includes, but is not limited to:

[0087] Volatile memory and / or non-volatile memory. Non-volatile memory can be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory can be random access memory (RAM), which is used as an external cache. By way of example, but not limitation, many forms of RAM are available, such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDR SDRAM), Enhanced Synchronous DRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), and Direct Rambus RAM (DR RAM).

[0088] In some embodiments of this application, the computer program may be divided into one or more modules, which are stored in the memory 510 and executed by the processor 520 to perform the method provided in this application. The one or more modules may be a series of computer program instruction segments capable of performing a specific function, which describe the execution process of the computer program in the electronic device.

[0089] like Figure 5 As shown, the electronic device may also include:

[0090] Transceiver 530, which can be connected to processor 520 or memory 510.

[0091] The processor 520 can control the transceiver 530 to communicate with other devices; specifically, it can send information or data to other devices or receive information or data sent by other devices. The transceiver 530 may include a transmitter and a receiver. The transceiver 530 may further include antennas, and the number of antennas may be one or more.

[0092] It should be understood that the various components in the electronic device are connected through a bus system, which includes a data bus, a power bus, a control bus, and a status signal bus.

[0093] This application also provides a computer storage medium storing a computer program thereon, which, when executed by a computer, enables the computer to perform the methods of the above-described method embodiments. Alternatively, this application also provides a computer program product containing instructions that, when executed by a computer, cause the computer to perform the methods of the above-described method embodiments.

[0094] When implemented using software, it can be implemented entirely or partially as a computer program product. This computer program product includes one or more computer instructions. When these computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another via wired (e.g., coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., digital video disc (DVD)), or a semiconductor medium (e.g., solid-state disk (SSD)).

[0095] Those skilled in the art will recognize that the modules and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0096] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or modules may be electrical, mechanical, or other forms.

[0097] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical modules; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. For example, the functional modules in the various embodiments of this application may be integrated into one processing module, or each module may exist physically separately, or two or more modules may be integrated into one module.

[0098] The above are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A method of data querying, characterized by, include: Real-time analysis of the current query characteristics of business data, which represent the changes in business data during historical queries, including at least three types: data query update time, data throughput, and query response time; Based on the current query characteristics, select the appropriate index mode from the configured multi-index modes; The business data query operation is performed using the adapted index pattern.

2. The method of claim 1, wherein, The step of selecting a suitable index mode from the configured multi-index modes based on the current query characteristics includes: Determine the query metrics for each index pattern within the configured multi-index pattern; The current query features are matched with the query metrics of each index pattern to determine the corresponding suitable index pattern.

3. The method of claim 2, wherein, The process of matching the current query features with the query metrics of each index pattern to determine the corresponding suitable index pattern includes: If the current query feature matches the query metrics of at least two index patterns, the corresponding suitable index pattern is determined according to the priority of each index pattern.

4. The method according to claim 1, characterized in that, The step of performing the query operation on the business data using the adapted index pattern includes: Switch the current index mode to the adapted index mode and run the adapted index mode to complete the query operation of the business data.

5. The method according to claim 1, characterized in that, After selecting the appropriate index mode from the configured multi-index modes, the following is also included: Perform route updates and load balancing configurations for the adapted index pattern.

6. The method according to claim 1, characterized in that, The current query characteristics of the business data include at least the data query update time, data throughput, and query response time.

7. A data query apparatus, characterized in that, include: The feature analysis module is used to analyze the current query features of business data in real time. The current query features represent the query changes of business data in the historical query process, including at least three types: data query update time, data throughput, and query response time. The pattern adaptation module is used to select the appropriate index pattern from the configured multi-index patterns based on the current query characteristics. The data query module is used to perform query operations on the business data using the adapted index mode.

8. An electronic device, characterized in that, include: A processor and a memory, the memory being used to store a computer program, the processor being used to invoke and run the computer program stored in the memory to perform the data query method according to any one of claims 1-6.

9. A computer-readable storage medium, characterized in that, Used to store computer programs that cause a computer to perform a data query method as described in any one of claims 1-6.

10. A computer program product comprising a computer program / instructions, characterized in that, When the computer program / instruction is executed by the processor, it implements the data query method as described in any one of claims 1-6.

Citation Information

Patent Citations

  • Database index optimization system

    CN105279276A

  • A method and apparatus for creating a database index

    CN109145004A

  • Information processing method, device and system, electronic equipment and storage medium

    CN110928874A

  • Government office document multi-machine retrieval method and system

    CN114064851A