CN116150206A - Method and device for retrieving data - Google Patents

Method and device for retrieving data Download PDF

Info

Publication number
CN116150206A
CN116150206A CN202310002127.6A CN202310002127A CN116150206A CN 116150206 A CN116150206 A CN 116150206A CN 202310002127 A CN202310002127 A CN 202310002127A CN 116150206 A CN116150206 A CN 116150206A
Authority
CN
China
Prior art keywords
index page
page
bit number
secondary index
primary
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310002127.6A
Other languages
Chinese (zh)
Inventor
姚杰
方洪祥
王洪原
汪方方
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Supcon Technology Co Ltd
Original Assignee
Zhejiang Supcon Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang Supcon Technology Co Ltd filed Critical Zhejiang Supcon Technology Co Ltd
Priority to CN202310002127.6A priority Critical patent/CN116150206A/en
Publication of CN116150206A publication Critical patent/CN116150206A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2455Query execution
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/22Indexing; Data structures therefor; Storage structures
    • G06F16/2228Indexing structures

Abstract

The application discloses a method and a device for retrieving data, which relate to the field of databases, and are characterized in that a first secondary index item is searched in a first secondary index page of a first bit number, the first secondary index item comprises time range information of the first primary index page and storage position information of the first primary index page, the time range indicated by the time range information comprises a target time point, the first primary index page is obtained based on the storage position information of the first primary index page, the first primary index item is searched from the first primary index page, the first primary index item comprises the target time point, the method for obtaining data of the first bit number at the target time point according to the first primary index item is adopted, and the quick positioning to the first primary index page is realized by reading one page of the second secondary index page and the same as reading multiple pages of the first primary index page, so that the quick retrieval of the data of the first bit number at the target time point is realized, and the data retrieval efficiency is improved.

Description

Method and device for retrieving data
Technical Field
The present invention relates to the field of databases, and in particular, to a method and apparatus for retrieving data.
Background
The bit data has the characteristics of large bit number quantity and high data conversion frequency, and the bit data has large annual production capacity and is usually required to be stored for five to ten years, so that the bit data is required to be stored in a plurality of archive files, and the required bit data is difficult to quickly retrieve from the plurality of archive files.
In the prior art, a plurality of archive files are firstly indexed according to bit numbers and time, then first-level index pages of the archive files are traversed, first-level index items in the first-level index pages are traversed after the first-level index pages are positioned, and finally the bit number data are read. The bit number data is searched through the prior art, and the search efficiency is lower.
Disclosure of Invention
In view of this, the present application provides a method and apparatus for retrieving data, so as to improve the efficiency of bit data retrieval.
The method for retrieving data provided by the application is realized by the following steps:
searching a first secondary index item in a first secondary index page of a first bit number, wherein the first secondary index item comprises time range information of the first primary index page and storage position information of the first primary index page, and a time range indicated by the time range information comprises a target time point;
acquiring a first-level index page based on storage position information of the first-level index page;
searching a first-level index item from the first-level index page, wherein the first-level index item comprises a target time point;
and obtaining the data of the first bit number at the target time point according to the first primary index item.
Optionally, the time range information in the first secondary index item includes a start time of the first bit number data and an end time of the last bit number data in the first primary index page, and the target time point is located between the start time and the end time.
Optionally, the storage location information in the first secondary index item includes an identifier of the first archive file and a first location identifier, and the acquiring the first primary index page based on the storage location information of the first primary index page includes:
acquiring a first archive file based on the identification of the first archive file;
a first primary index page is determined from the first archive based on the first location identification.
Optionally, the first secondary index page is stored in a second archive file.
Optionally, the first secondary index page further includes an identification of a second secondary index page of the first bit number, the second secondary index page being a previous page of the first secondary index page, and an identification of a third secondary index page of the first bit number, the third secondary index page being a subsequent page of the first secondary index page.
Optionally, before searching the first secondary index item in the first secondary index page of the first bit number, the method further includes:
based on the target point in time, a first secondary index page is found among the plurality of secondary index pages of the first bit number.
Optionally, based on the target point in time, searching for the first secondary index page among the plurality of secondary index pages of the first bit number includes:
in response to determining that the time range information in the third secondary index page of the first bit number does not include the target point in time, the first secondary index page is determined based on an identification of the first secondary index page in the third secondary index page.
Optionally, before searching the first secondary index item in the first secondary index page of the first bit number, the method further includes:
receiving a storage request, wherein the storage request indicates to store the data of the first bit number at a target time point;
creating a first primary index page based on the data of the first bit number at the target time point and the target time point;
a first secondary index item is created based on the time range information of the first primary index page and the storage location information of the first primary index page.
Optionally, the method further comprises:
inserting a second-level index item into the first-level index page of the first bit number to obtain a second-level index page;
the time range information in the first level two index item is updated to the time range information of the second level one index page.
The application also provides a device for retrieving data, comprising: a searching unit and an acquiring unit;
the searching unit is used for searching a first secondary index item in a first secondary index page of a first bit number, wherein the first secondary index item comprises time range information of the first primary index page and storage position information of the first primary index page, the time range indicated by the time range information comprises a target time point, and the searching unit is used for searching the first primary index item from the first primary index page, and the first primary index item comprises the target time point;
and the acquisition unit is used for acquiring the first primary index page based on the storage position information of the first primary index page and acquiring the data of the first bit number at the target time point according to the first primary index item.
The present application also provides a computer device comprising: and a processor coupled to the memory, the memory storing at least one computer program instruction, the at least one computer program instruction being loaded and executed by the processor to cause the computer device to implement a method of retrieving data.
Therefore, the beneficial effects of this application are: the method comprises the steps of searching a first secondary index item in a first secondary index page of a first bit number, wherein the first secondary index item comprises time range information of the first primary index page and storage position information of the first primary index page, the time range indicated by the time range information comprises a target time point, acquiring the first primary index page based on the storage position information of the first primary index page, searching the first primary index item from the first primary index page, wherein the first primary index item comprises the target time point, acquiring data of the first bit number at the target time point according to the first primary index item, and realizing quick positioning to the first primary index page by reading one page of the second secondary index page.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings that are required to be used in the embodiments or the description of the prior art will be briefly described below, and it is obvious that the drawings in the following description are only embodiments of the present application, and that other drawings may be obtained according to the provided drawings without inventive effort to a person skilled in the art.
FIG. 1 is a flow chart of a first embodiment of the present application;
FIG. 2 is a schematic diagram of an index page of the present application;
FIG. 3 is a flow chart of a second embodiment of the present application;
FIG. 4 is a flow chart of a third embodiment of the present application;
FIG. 5 is a schematic diagram of one search data of the present application;
FIG. 6 is a schematic view of an apparatus of the present application;
fig. 7 is a schematic diagram of a computer device of the present application.
Detailed Description
The following description of the embodiments of the present application will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are only some, but not all, of the embodiments of the present application. All other embodiments, which can be made by one of ordinary skill in the art without undue burden from the present disclosure, are within the scope of the present disclosure.
The inventor finds that the archive files store the starting time and the ending time of all bit number data in the archive files, whether the archive files are divided by a fixed size or by a fixed time length, a plurality of archive files are overlapped in time, the archive files where the bit number data are located cannot be directly located when the bit number data are searched, and multiple first-level index page reading needs to be carried out. According to the method and the device, the secondary index item is built for the primary index page, and reading one secondary index page is equivalent to reading a plurality of primary index pages, so that the number of times of reading the primary index page is reduced, and the retrieval efficiency of bit number data is improved.
In embodiments of the present application, the device that retrieves data may include, but is not limited to, a computer device.
The computer device may include: and a processor coupled to the memory, the memory storing at least one computer program instruction, the at least one computer program instruction being loaded and executed by the processor to cause the computer device to implement a method of retrieving data.
Referring to fig. 1, the specific steps of the first embodiment of the present application are as follows:
s101: the computer searches for the first secondary index item in the first secondary index page of the first bit number.
The first secondary index item includes time range information of the first primary index page and storage location information of the first primary index page, and a time range indicated by the time range information includes a target point in time.
The time range information comprises a starting time of the first bit number data and an ending time of the last bit number data in the first primary index page, and the target time point is positioned in the starting time to the ending time.
The position number is an input/output point of the industrial control site and is used for collecting signals of any device of the industrial control site, wherein the signals can be temperature, pressure, flow and other signals set according to requirements. The first bit number may be any one bit number.
The bit number data may be data of a bit number at a certain moment, and may also be stored in the form of a data block for data of a bit number for a period of time. The bit number data may include a time stamp indicating the time at which the bit number data was generated, a quality code indicating whether the bit number data is authentic, and a value indicating a reading of meter data that tested the bit number. The bit number data can be stored in the first-level index page according to the bit number so as to facilitate the retrieval of the bit number data.
The second-level index items are stored in a second archive file, the second archive file takes pages as units, each page is a second-level index page, and all the second-level index items in the same second-level index page belong to the same bit number. Any secondary index entry indicates a page of primary index pages. I.e., the first secondary index page is stored in the second archive file.
Referring to fig. 2, in addition to index items, the index pages may further include prev and next fields for concatenating multiple index pages of the same bit number in the same archive file. Index pages with the same bit number in the same archive file are connected in series in a doubly linked list mode, and no relation exists between the index pages of different archive files. In some implementations, the secondary index page may further include an identification of a second secondary index page of the first bit number, the second secondary index page being a preceding page of the first secondary index page, and an identification of a third secondary index page of the first bit number, the second secondary index page and the third secondary index page both being index pages of the first bit number.
The first secondary index page is a secondary index page containing a first secondary index item, and the first secondary index item is a secondary index item whose time range contains a target point in time.
In other implementations, the computer looks up the first 5 secondary index item in a first secondary index page of the first bit number based on the target point in time before looking up the first secondary index item in a plurality of secondary index pages of the first bit number
Find the first secondary index page.
In other implementations, the computer is responsive to determining the time range information in a third secondary index page of the first bit number before locating the first secondary index entry in the first secondary index page of the first bit number
The information does not include a target point in time, and a first secondary index page is determined 0 based on an identification of the first secondary index page in the third secondary index page.
The third secondary index page is a page subsequent to the first secondary index page. Alternatively, the third secondary index page may be the most recent secondary index page of the first bit number.
S102: the computer obtains the first-level index page based on the storage location information of the first-level index page.
5 the storage location information of the first primary index page includes an identification of the first archive file and a first bit
The first location identifier is used for indicating the location of the first primary index page stored in the first archive file.
In some implementations, the computer obtains the first archive file based on the identification of the first archive file, and determines the first primary index page from the first archive file based on the first location identification.
0S103: the computer searches the first primary index item from the first primary index page.
The first primary index entry includes a target point in time.
The first primary index page is a primary index page containing a first primary index item, which is a primary index item containing a target point in time.
S104: and the computer obtains the data of the first bit number at the target time point according to the first primary index item. The 5 first primary index entry indicates the data of the first bit number at the target point in time.
In some implementations, if the bit number data is stored in the form of a data block, the computer obtains a first data block according to the first primary index entry, where the first data block includes data of the first bit number at the target time point.
In the first embodiment of the application, the reading of the second-level index page of one page is equivalent to the reading of the first-level index page of multiple pages, so that the first-level index page is quickly positioned, the quick retrieval of the data of the first bit number at the target time point is realized, the number of IO reading of the magnetic disk is reduced, and the data retrieval efficiency is improved.
The second embodiment describes the case in which there is a need to insert bit data between existing bit data, such as history bit data import or history bit data disconnection.
Referring to fig. 3, the specific steps of the second embodiment of the present application are as follows:
s301: and the computer inserts a second-level index item into the first-level index page of the first bit number to obtain a second-level index page.
S302: the computer updates the time range information in the first level two index item to the time range information of the second level one index page.
S303: the computer searches for a first secondary index page among a plurality of secondary index pages of a first bit number based on the target point in time.
S304: the computer searches for the first secondary index item in the first secondary index page of the first bit number.
The first secondary index item includes time range information of the second primary index page and storage location information of the second primary index page, and a time range indicated by the time range information includes a target point in time.
The storage location information of the second level index page includes an identification of the first archive file for indicating that the second level index page is stored in the first archive file and a first location identification for indicating a location of the second level index page stored in the first archive file.
The time range information comprises a starting time of the first bit number data and an ending time of the last bit number data in the second-level index page, and the target time point is positioned in the starting time to the ending time.
S305: the computer obtains the first archive file based on the identification of the first archive file.
S306: the computer determines a second level index page from the first archive based on the first location identification.
S307: the computer searches the first primary index item from the second primary index page.
S308: and the computer obtains the data of the first bit number at the target time point according to the first primary index item.
In the second embodiment of the present application, when the primary index item in the primary index page changes, the secondary index item corresponding to the primary index page is updated, so that the content of the primary index page obtained when the secondary index item is queried is updated content.
The third embodiment describes a case where a first secondary index page is found by combining a case where a plurality of secondary index pages need to be read, because there is a case where new bit number data cannot be saved in an existing primary index page when a new bit number data is dropped.
Referring to fig. 4 to 5, the third embodiment of the present application comprises the following specific steps:
s401: the computer receives a storage request indicating to save the data of the first bit number at the target point in time.
In some implementations, a computer receives a storage request indicating to store data of a second bit number at a first point in time (the first point in time may be any point in time including a target point in time).
The second bit number may be any bit number other than the first bit number.
S402: the computer creates a first primary index page based on the data of the first bit number at the target point in time and the target point in time.
In some implementations, the computer creates the second level index page based on the data of the second bit number at the first point in time and the first point in time.
S403: the computer creates a first secondary index item based on the time range information of the first primary index page and the storage location information of the first primary index page.
In some implementations, the computer creates the second level index item based on the time range information of the second level index page and the storage location information of the second level index page.
S404: the computer determines a first secondary index page based on an identification of the first secondary index page in the third secondary index page in response to determining that the time range information in the third secondary index page of the first bit number does not include the target point in time.
In some implementations, the fourth secondary index page is a last secondary index page of the first bit number, and the computer determines the third secondary index page based on an identification of the third secondary index page in the fourth secondary index page in advance in response to determining that the time range information in the fourth secondary index page of the first bit number does not include the target time point, thereby determining whether the time range information in the third secondary index page includes the target time point.
In other implementations, the computer reads from the latest secondary index page of the first bit number, sequentially determines whether the time range information in each secondary index page includes a target time point, and performs subsequent operations according to the secondary index page whose time range information includes the target time point until it is determined that the time range information of one secondary index page includes the target time point.
S405: the computer searches for the first secondary index item in the first secondary index page of the first bit number.
The first secondary index item includes time range information of the first primary index page and storage location information of the first primary index page, and a time range indicated by the time range information includes a target point in time.
The storage location information of the first primary index page includes an identification of the first archive file indicating that the first primary index page is stored in the first archive file and a first location identification indicating a location of the first primary index page stored in the first archive file.
The time range information comprises a starting time of the first bit number data and an ending time of the last bit number data in the first primary index page, and the target time point is positioned in the starting time to the ending time.
S406: the computer obtains the first archive file based on the identification of the first archive file.
S407: the computer determines a first primary index page from the first archive based on the first location identification.
S408: the computer searches the first primary index item from the first primary index page.
S409: and the computer obtains the data of the first bit number at the target time point according to the first primary index item.
In the third embodiment of the present application, by newly building a corresponding secondary index item when a primary index page is newly added, each primary index page has a corresponding secondary index item, and by querying the secondary index item, bit number data in a primary index page to be retrieved can be quickly retrieved.
Referring to fig. 6, the present application provides an apparatus 600 for retrieving data, including: a search unit 601 and an acquisition unit 602.
The search unit 601: the method comprises the steps of searching a first secondary index item in a first secondary index page of a first bit number, wherein the first secondary index item comprises time range information of the first primary index page and storage position information of the first primary index page, a time range indicated by the time range information comprises a target time point, and the method is used for searching the first primary index item from the first primary index page, and the first primary index item comprises the target time point.
Optionally, the search unit 601: and searching for the first secondary index page among the plurality of secondary index pages of the first bit number based on the target point in time.
The acquisition unit 602: the method comprises the steps of acquiring a first primary index page based on storage position information of the first primary index page, and acquiring data of a first bit number at a target time point according to a first primary index item.
Alternatively, the acquisition unit 602: the first index page is further used for obtaining the first archive file based on the identification of the first archive file, and determining the first index page from the first archive file based on the first position identification.
Optionally, the apparatus 600 for retrieving data further includes: a determination unit 603, a reception unit 604, a creation unit 605, an insertion unit 606, and an update unit 607.
Determination unit 603: and determining the first secondary index page based on the identification of the first secondary index page in the third secondary index page in response to determining that the time range information in the third secondary index page of the first bit number does not include the target point in time.
The receiving unit 604: for receiving a storage request indicating to save the data of the first bit number at the target point in time.
The creation unit 605: and creating a first primary index page at a target time point based on the data of the first bit number at the target time point, and creating a first secondary index item based on the time range information of the first primary index page and the storage position information of the first primary index page.
The insertion unit 606: and the second-level index page is obtained by inserting a second-level index item into the first-level index page of the first bit number.
The updating unit 607: for updating the time range information in the first level two index item to the time range information of the second level one index page.
The specific manner in which the various modules perform the operations in the apparatus of the above embodiments have been described in detail in connection with the embodiments of the method, and will not be described in detail herein.
It should be noted that: in the data retrieving apparatus provided in the foregoing embodiment, only the division of the functional modules is used for illustration when implementing the data retrieving function, and in practical application, the functional allocation may be performed by different functional modules according to needs, that is, the internal structure of the data retrieving apparatus is divided into different functional modules, so as to complete all or part of the functions described above. In addition, the apparatus for retrieving data provided in the foregoing embodiments and the method embodiment for retrieving data belong to the same concept, and detailed implementation processes of the apparatus for retrieving data are shown in the method embodiment, which is not repeated herein.
Fig. 7 is a schematic structural diagram of a computer device 700 according to an embodiment of the present application.
The computer device 700 includes at least one processor 701, memory 702, and at least one network interface 703.
The processor 701 is, for example, a general-purpose central processing unit (central processing unit, CPU), a network processor (network processer, NP), a graphics processor (graphics processing unit, GPU), a neural-network processor (neural-network processing units, NPU), a data processing unit (data processing unit, DPU), a microprocessor, or one or more integrated circuits for implementing the aspects of the present application. For example, the processor 701 includes an application-specific integrated circuit (ASIC), a programmable logic device (programmable logic device, PLD), or a combination thereof. PLDs are, for example, complex programmable logic devices (complex programmable logic device, CPLD), field-programmable gate arrays (field-programmable gate array, FPGA), general-purpose array logic (generic array logic, GAL), or any combination thereof.
The Memory 702 is, for example, but not limited to, a read-only Memory (ROM) or other type of static storage device that can store static information and instructions, as well as a random access Memory (random access Memory, RAM) or other type of dynamic storage device that can store information and instructions, as well as an electrically erasable programmable read-only Memory (electrically erasable programmable read-only Memory, EEPROM), compact disc read-only Memory (compact disc read-only Memory) or other optical disc storage, optical disc storage (including compact disc, laser disc, optical disc, digital versatile disc, blu-ray disc, etc.), magnetic disk storage media, or other magnetic storage device, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer. Alternatively, the memory 702 is independent and is coupled to the processor 701 via an internal connection 704. Alternatively, memory 702 and processor 701 may be integrated.
The network interface 703 uses any transceiver-like device for communicating with other devices or communication networks. The network interface 703 includes, for example, at least one of a wired network interface or a wireless network interface. The wired network interface is, for example, an ethernet interface. The ethernet interface is, for example, an optical interface, an electrical interface, or a combination thereof. The wireless network interface is, for example, a wireless local area network (wireless local area networks, WLAN) interface, a cellular network interface, a combination thereof, or the like.
In some embodiments, processor 701 includes one or more CPUs, such as CPU0 and CPU1 shown in fig. 7.
In some embodiments, computer device 700 optionally includes multiple processors, such as processor 701 and processor 705 shown in fig. 7. Each of these processors is, for example, a single-core processor (single-CPU), and is, for example, a multi-core processor (multi-CPU). A processor herein may optionally refer to one or more devices, circuits, and/or processing cores for processing data (e.g., computer program instructions).
In some embodiments, computer device 700 also includes internal connection 704. The processor 701, the memory 702 and the at least one network interface 703 are connected by an internal connection 704. The internal connections 704 include pathways that communicate information between the components described above. Optionally, internal connection 704 is a board or bus. Optionally, the internal connections 704 are divided into address buses, data buses, control buses, etc.
In some embodiments, computer device 700 also includes an input-output interface 706. An input-output interface 706 is connected to the internal connection 704.
In some embodiments, the input-output interface 706 is configured to interface with an input device, and receive commands or data related to the above-described embodiments that are input by a user via the input device. Input devices include, but are not limited to, a keyboard, touch screen, microphone, mouse or sensing device, and the like.
In some embodiments, the input-output interface 706 is also used to connect with an output device. The input-output interface 706 outputs intermediate and/or final results produced by the processor 701 executing the above-described method embodiments via an output device. Output devices include, but are not limited to, displays, printers, projectors, and so forth.
Alternatively, the processor 701 implements the method in the above embodiment by reading the program code stored in the memory 702, or the processor 701 implements the method in the above embodiment by internally storing the program code. In the case where the processor 701 implements the method in the above embodiment by reading the program code stored in the memory 702, the program code 710 implementing the method provided in the embodiment of the present application is stored in the memory 702.
For more details on the implementation of the above-described functions by the processor 701, reference is made to the description of the previous method embodiments, which is not repeated here.
Finally, it is further noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the application. Thus, the present application is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (11)

1. A method of retrieving data, the method comprising:
searching a first secondary index item in a first secondary index page of a first bit number, wherein the first secondary index item comprises time range information of the first primary index page and storage position information of the first primary index page, and a time range indicated by the time range information comprises a target time point;
acquiring the first primary index page based on the storage position information of the first primary index page;
searching a first primary index item from the first primary index page, wherein the first primary index item comprises the target time point;
and obtaining the data of the first bit number at the target time point according to the first primary index item.
2. The method of claim 1, wherein the time range information in the first secondary index entry includes a start time of a first bit number data and an end time of a last bit number data in the first primary index page, the target point in time being located within the start time to the end time.
3. The method of claim 1, wherein the storage location information in the first secondary index item includes an identification of a first archive file and a first location identification, wherein the obtaining the first primary index page based on the storage location information of the first primary index page comprises:
obtaining the first archive file based on the identification of the first archive file;
the first primary index page is determined from the first archive based on the first location identification.
4. The method of claim 1, wherein the first secondary index page is stored in a second archive file.
5. The method of any of claims 1-4, wherein the first secondary index page further comprises an identification of a second secondary index page of the first bit number that is a previous page of the first secondary index page and an identification of a third secondary index page of the first bit number that is a subsequent page of the first secondary index page.
6. The method of claim 1, wherein prior to locating the first secondary index entry in the first secondary index page of the first bit number, the method further comprises:
and searching the first secondary index page in a plurality of secondary index pages of the first bit number based on the target time point.
7. The method of claim 6, wherein the looking up the first secondary index page among the plurality of secondary index pages of the first bit number based on the target point in time comprises:
in response to determining that the time range information in a third secondary index page of the first bit number does not include the target point in time, the first secondary index page is determined based on an identification of the first secondary index page in the third secondary index page.
8. The method of claim 1, wherein prior to locating the first secondary index entry in the first secondary index page of the first bit number, the method further comprises:
receiving a storage request, wherein the storage request indicates to store the data of the first bit number at the target time point;
creating the first primary index page based on the data of the first bit number at the target time point and the target time point;
the first secondary index item is created based on the time range information of the first primary index page and the storage location information of the first primary index page.
9. The method according to claim 1, wherein the method further comprises:
inserting a second-level index item into the first-level index page of the first bit number to obtain a second-level index page;
and updating the time range information in the first secondary index item into the time range information of the second primary index page.
10. An apparatus for retrieving data, the apparatus comprising: a searching unit and an acquiring unit;
the searching unit is configured to search a first secondary index item in a first secondary index page with a first bit number, where the first secondary index item includes time range information of the first primary index page and storage location information of the first primary index page, and a time range indicated by the time range information includes a target time point, and is configured to search the first primary index item from the first primary index page, where the first primary index item includes the target time point;
the acquisition unit is configured to acquire the first level index page based on storage location information of the first level index page, and obtain data of the first bit number at the target time point according to the first level index item.
11. A computer device, the computer device comprising: a processor coupled to a memory having stored therein at least one computer program instruction that is loaded and executed by the processor to cause the computer arrangement to implement the method of any of claims 1-9.
CN202310002127.6A 2023-01-03 2023-01-03 Method and device for retrieving data Pending CN116150206A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310002127.6A CN116150206A (en) 2023-01-03 2023-01-03 Method and device for retrieving data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310002127.6A CN116150206A (en) 2023-01-03 2023-01-03 Method and device for retrieving data

Publications (1)

Publication Number Publication Date
CN116150206A true CN116150206A (en) 2023-05-23

Family

ID=86340140

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310002127.6A Pending CN116150206A (en) 2023-01-03 2023-01-03 Method and device for retrieving data

Country Status (1)

Country Link
CN (1) CN116150206A (en)

Similar Documents

Publication Publication Date Title
US5848416A (en) Method and apparatus for storing and retrieving data and a memory arrangement
US8190591B2 (en) Bit string searching apparatus, searching method, and program
WO2018129500A1 (en) Optimized navigable key-value store
CN107992577B (en) Hash table data conflict processing method and device
CN111427885B (en) Database management method and device based on lookup table
CN111309868B (en) Knowledge graph construction and retrieval method and device
CN111061802B (en) Power data management processing method, device and storage medium
CN113918605A (en) Data query method, device, equipment and computer storage medium
CN112486988A (en) Data processing method, device, equipment and storage medium
CN111858606A (en) Data processing method and device and electronic equipment
CN116150206A (en) Method and device for retrieving data
CN110709824B (en) Data query method and device
CN114048238B (en) Storage method and device for industrial equipment time sequence data and electronic equipment
CN114595215A (en) Data processing method and device, electronic equipment and storage medium
CN114896252A (en) Query method and device for Internet of things equipment, computer equipment and storage medium
CN116049180A (en) Tenant data processing method and device for Paas platform
CN114840487A (en) Metadata management method and device for distributed file system
CN115221360A (en) Tree structure configuration method and system
CN113868138A (en) Method, system, equipment and storage medium for acquiring test data
CN111651466A (en) Data sampling method and device
JP2005234945A (en) Concurrent execution control method and device
CN110968267A (en) Data management method, device, server and system
CN110825846A (en) Data processing method and device
CN117909301A (en) Index-based object query method, device, equipment and medium
CN117829044B (en) EDA constraint detection system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination