WO2022127114A1 - Data storage method and apparatus, and storage medium and server - Google Patents

Data storage method and apparatus, and storage medium and server Download PDF

Info

Publication number
WO2022127114A1
WO2022127114A1 PCT/CN2021/108064 CN2021108064W WO2022127114A1 WO 2022127114 A1 WO2022127114 A1 WO 2022127114A1 CN 2021108064 W CN2021108064 W CN 2021108064W WO 2022127114 A1 WO2022127114 A1 WO 2022127114A1
Authority
WO
WIPO (PCT)
Prior art keywords
node
data
path information
database
tree structure
Prior art date
Application number
PCT/CN2021/108064
Other languages
French (fr)
Chinese (zh)
Inventor
王晓
谢永恒
程强
冯宇波
Original Assignee
北京锐安科技有限公司
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 北京锐安科技有限公司 filed Critical 北京锐安科技有限公司
Publication of WO2022127114A1 publication Critical patent/WO2022127114A1/en

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/22Indexing; Data structures therefor; Storage structures
    • G06F16/2228Indexing structures
    • G06F16/2246Trees, e.g. B+trees
    • 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
    • G06F16/2264Multidimensional index structures
    • 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
    • G06F16/24564Applying rules; Deductive queries
    • G06F16/24566Recursive queries

Abstract

A data storage method and apparatus, and a storage medium and a server. The data storage method comprises: acquiring path information of each piece of node data from tree structure data, wherein the path information is used for indicating a path from a root node of a tree structure to a node corresponding to current node data, and the tree structure is a structural relationship presented by the tree structure data (S301); and storing the path information of each piece of node data and corresponding node data in a database (S302).

Description

一种数据存储方法、装置、存储介质及服务器A data storage method, device, storage medium and server
本申请要求在2020年12月18日提交中国专利局、申请号202011502922.4的中国专利申请的优先权,该申请的全部内容通过引用结合在本申请中。This application claims the priority of the Chinese patent application with application number 202011502922.4 filed with the China Patent Office on December 18, 2020, the entire contents of which are incorporated herein by reference.
技术领域technical field
本申请实施例涉及数据处理技术领域,例如涉及一种数据存储方法、装置、存储介质及服务器。The embodiments of the present application relate to the technical field of data processing, for example, to a data storage method, device, storage medium, and server.
背景技术Background technique
为了满足对多层级关联关系数据的处理需求,一般在存储多层级关联关系数据的数据库中,采用parent_code(父级编码)的定义,当通过结构化查询语言(Structured Query Language,SQL)查询时,基于自关联操作来实现由二维数据到多维数据的展示,再通过对象关系映射(Object Relational Mapping,ORM)框架实现数据库信息与实体对象的映射,最终将实体对象通过前端技术展示在页面上。In order to meet the processing requirements of multi-level relationship data, the definition of parent_code (parent code) is generally used in the database storing multi-level relationship data. When querying through Structured Query Language (SQL), Based on the self-association operation, the display from two-dimensional data to multi-dimensional data is realized, and then the mapping between database information and entity objects is realized through the Object Relational Mapping (ORM) framework, and finally the entity objects are displayed on the page through front-end technology.
当进行数据查询时,一般采用传入父级节点编码的形式来进行递归查询,针对有多层级关系的数据,在Oracle数据库中可以根据connect by函数来实现递归查询,而对于其他关系型数据库,如MySQL数据库,则需要设计递归查询程序进行查询。然而,随着树形结构数据层级关系的不断增长,查询的时间复杂度和空间复杂度也在不断递增,运行效率偏低。因此,如何对多层级关联关系数据进行存储,以在进行数据读取时简单、快速还原树形结构数据关系,变得至关重要。When performing data query, recursive query is generally performed in the form of passing in the parent node code. For data with multi-level relationships, recursive query can be implemented in Oracle database according to the connect by function, while for other relational databases, Such as MySQL database, you need to design a recursive query program to query. However, with the continuous growth of the hierarchical relationship of tree-structured data, the time complexity and space complexity of the query are also increasing, and the operating efficiency is low. Therefore, how to store the multi-level relational data so as to restore the tree-structured data relation simply and quickly when reading the data becomes very important.
发明内容SUMMARY OF THE INVENTION
本申请实施例提供一种数据存储方法、装置、存储介质及服务器,可以增 加树形结构数据存储的灵活性和可扩展性。The embodiments of the present application provide a data storage method, device, storage medium, and server, which can increase the flexibility and scalability of tree-structured data storage.
第一方面,本申请实施例提供了一种数据存储方法,包括:In a first aspect, an embodiment of the present application provides a data storage method, including:
获取树形结构数据中每个节点数据的路径信息;其中,所述路径信息用于指示树形结构的根节点到当前节点数据所对应节点的路径,所述树形结构为所述树形结构数据所呈现的结构关系;Obtain the path information of each node data in the tree structure data; wherein, the path information is used to indicate the path from the root node of the tree structure to the node corresponding to the current node data, and the tree structure is the tree structure The structural relationships presented by the data;
将所述每个节点数据的路径信息及对应的节点数据存储于数据库中。The path information of each node data and the corresponding node data are stored in the database.
第二方面,本申请实施例还提供了一种数据存储装置,包括:In a second aspect, an embodiment of the present application further provides a data storage device, including:
路径信息获取模块,设置为获取树形结构数据中每个节点数据的路径信息;其中,所述路径信息用于指示树形结构的根节点到当前节点数据所对应节点的路径,所述树形结构为所述树形结构数据所呈现的结构关系;A path information acquisition module, configured to acquire path information of each node data in the tree structure data; wherein, the path information is used to indicate the path from the root node of the tree structure to the node corresponding to the current node data, the tree structure The structure is the structural relationship presented by the tree structure data;
存储模块,设置为将所述每个节点数据的路径信息及对应的节点数据存储于数据库中。The storage module is configured to store the path information of each node data and the corresponding node data in the database.
第三方面,本申请实施例提供了一种计算机可读存储介质,其上存储有计算机程序,该程序被处理器执行时实现如本申请第一方面所述的数据存储方法。In a third aspect, an embodiment of the present application provides a computer-readable storage medium on which a computer program is stored, and when the program is executed by a processor, implements the data storage method described in the first aspect of the present application.
第四方面,本申请实施例提供了一种服务器,包括:In a fourth aspect, an embodiment of the present application provides a server, including:
至少一个处理器;at least one processor;
存储器,设置为存储至少一个程序;a memory, arranged to store at least one program;
当所述至少一个程序被所述至少一个处理器执行,使得所述至少一个处理器实现如本申请第一方面所述数据存储方法。When the at least one program is executed by the at least one processor, the at least one processor implements the data storage method according to the first aspect of the present application.
附图说明Description of drawings
图1是相关技术中的树形结构数据的存储结构示意图;1 is a schematic diagram of a storage structure of tree-structured data in the related art;
图2是相关技术中的另一种多层级关联关系数据的存储结构示意图;Fig. 2 is another kind of storage structure schematic diagram of multi-level relationship data in the related art;
图3是本申请实施例一提供的一种数据存储方法的流程示意图;3 is a schematic flowchart of a data storage method provided in Embodiment 1 of the present application;
图4是本申请实施例一提供的树形结构数据所呈现的树形结构示意图;4 is a schematic diagram of a tree structure presented by tree structure data provided in Embodiment 1 of the present application;
图5是本申请实施例一提供的树形结构数据的存储结构示意图;5 is a schematic diagram of a storage structure of tree-structured data provided in Embodiment 1 of the present application;
图6是本申请实施例二提供的一种数据存储方法的流程图;6 is a flowchart of a data storage method provided in Embodiment 2 of the present application;
图7是本申请实施例三提供的一种数据存储装置的结构示意图;7 is a schematic structural diagram of a data storage device according to Embodiment 3 of the present application;
图8是本申请实施例五提供的一种服务器的结构示意图。FIG. 8 is a schematic structural diagram of a server according to Embodiment 5 of the present application.
具体实施方式Detailed ways
下面结合附图和实施例对本申请作详细说明。The present application will be described in detail below with reference to the accompanying drawings and embodiments.
在更加详细地讨论示例性实施例之前应当提到的是,一些示例性实施例被描述成作为流程图描绘的处理或方法。虽然流程图将各步骤描述成顺序的处理,但是其中的许多步骤可以被并行地、并发地或者同时实施。此外,各步骤的顺序可以被重新安排。当其操作完成时所述处理可以被终止,但是还可以具有未包括在附图中的附加步骤。所述处理可以对应于方法、函数、规程、子例程、子程序等等。Before discussing the exemplary embodiments in greater detail, it should be mentioned that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although the flowchart depicts the steps as a sequential process, many of the steps may be performed in parallel, concurrently, or concurrently. Furthermore, the order of the steps can be rearranged. The process may be terminated when its operation is complete, but may also have additional steps not included in the figures. The processes may correspond to methods, functions, procedures, subroutines, subroutines, and the like.
图1为相关技术中的树形结构数据的存储结构示意图。如图1所示,树形结构数据(也即多层级关联关系数据)的存储结构主要由三个字段组成,节点编码(code),节点名称(name)和父级节点编码(parent_code),可以通过表内自关联的形式来保存数据以及数据之间的上下级关系,将由多层级关联关系的数据降维成二维数据进行存储。当进行数据读取时需要还原数据关系,而在还原数据关系的过程中基于递归的运算逻辑,才能完整的还原树形结构数据,最终展示在客户端上。对于Oracle数据库,可以使用数据库特殊函数,如connect by函数实现递归查询,而对于其他关系型数据库,需要使用程序嵌套循环来实现递归,然而,随着树形结构数据层级关系的不断增长,查询的时间复杂度和空间复杂度也在不断递增,运行效率偏低。FIG. 1 is a schematic diagram of a storage structure of tree-structured data in the related art. As shown in Figure 1, the storage structure of tree structure data (that is, multi-level association data) is mainly composed of three fields, node code (code), node name (name) and parent node code (parent_code). The data and the superior-subordinate relationship between the data are stored in the form of self-association in the table, and the data with multi-level association relationship is reduced to two-dimensional data for storage. When reading data, it is necessary to restore the data relationship. In the process of restoring the data relationship, based on the recursive operation logic, the tree-structured data can be completely restored and finally displayed on the client. For Oracle database, you can use special database functions, such as connect by function to implement recursive query, while for other relational databases, you need to use program nested loop to achieve recursion, however, with the continuous growth of tree-structured data hierarchy, query The time complexity and space complexity are also increasing, and the operating efficiency is low.
相关技术中,为了解决基于父级节点编码形式进行递归查询时,由于树形结构数据层级关系的不断增长,查询的时间复杂度和空间复杂度会不断递增,运行效率偏低的技术问题,提出一种解决方案——在数据库中提前定义好数据 所属层级,则在查询过程中可以针对层级来有目的的查询。图2为相关技术中的另一种树形结构数据的存储结构示意图。如图2所示,在图1提供的树形结构数据的存储结构中增加了level层级字段,将数据所在的层级规划明确,这样在读取数据时,可以任意制定层级,不需要逐级遍历。但这种方式也使数据在某种意义上失去了自动扩展的可行性,同时在开发过程中限定了程序实现方式,不便于灵活扩展。In the related art, in order to solve the technical problem that the time complexity and space complexity of the query will continue to increase, and the operation efficiency is low due to the continuous growth of the hierarchical relationship of the tree structure data when the recursive query is performed based on the coding form of the parent node, it is proposed. One solution is to define the level to which the data belongs in advance in the database, so that the level can be purposefully queried during the query process. FIG. 2 is a schematic diagram of another storage structure of tree-structured data in the related art. As shown in Figure 2, the level field is added to the storage structure of the tree structure data provided in Figure 1, and the level of the data is clearly planned, so that when reading the data, the level can be arbitrarily defined, and there is no need to traverse level by level. . However, this method also makes the data lose the feasibility of automatic expansion in a sense, and at the same time limits the program implementation method during the development process, which is not convenient for flexible expansion.
实施例一Example 1
图3为本申请实施例一提供的数据存储方法的流程示意图,该方法可适用于服务器对多层级关联关系的数据进行存储的情况,可以由数据存储装置执行,其中该装置可由软件和/或硬件实现,一般可集成在服务器中。如图3所示,该方法包括:3 is a schematic flowchart of a data storage method provided in Embodiment 1 of the present application. The method is applicable to a situation where a server stores data in a multi-level association relationship, and can be executed by a data storage device, wherein the device can be implemented by software and/or Hardware implementation, generally can be integrated in the server. As shown in Figure 3, the method includes:
S301、获取树形结构数据中每个节点数据的路径信息;其中,所述路径信息用于指示树形结构的根节点到当前节点数据所对应节点的路径,所述树形结构为所述树形结构数据所呈现的结构关系。S301. Obtain path information of each node data in the tree structure data; wherein, the path information is used to indicate the path from the root node of the tree structure to the node corresponding to the current node data, and the tree structure is the tree The structural relationship presented by the shape structure data.
在本申请实施例中,树形结构数据为有明显的上下级且多层级关联关系的数据,树形结构数据包括若干个节点和若干节点数据,每个节点与每个节点数据对应。树形结构为树形结构数据所呈现的结构关系,在树形结构中包含多个父子关系,多个父子关系构成了树形结构,也即树形结构数据中的节点数据之间存在父子关系。In the embodiment of the present application, the tree-structured data is data with obvious upper-lower and multi-level associations, the tree-structured data includes several nodes and several node data, and each node corresponds to each node data. The tree structure is the structural relationship presented by the tree structure data. The tree structure contains multiple parent-child relationships, and multiple parent-child relationships form the tree structure, that is, there is a parent-child relationship between the node data in the tree structure data. .
树形结构数据中每个节点数据的路径信息包括从树形结构的根节点到当前节点数据所对应节点的路径,也即从树形结构的根节点到当前节点数据所处节点需要走过的路径。可以理解的是,每个节点数据的路径信息包括当前节点数据所处的当前节点及其所有的父节点,通过路径信息可以表征每个节点数据在整个树形结构中所处的位置。示例性的,图4为本申请实施例提供的树形结构 数据所呈现的树形结构示意图。如图4所示,该树形结构中的节点E处的节点数据的路径信息为:从节点A开始,途经节点B,再途经节点D,最终才能达到节点E。可选的,所述路径信息由节点编码和预设分隔符组成,多个节点编码之间用所述预设分隔符分隔,所述路径信息以所述预设分隔符结尾。如图4所示,在该树形结构中的各节点编码用A、B、C、D、F、G、H、I、J及K表示,预设分隔符可以为“-”,节点E对应的节点数据的路径信息可以表示为:“A-B-D-E-”。The path information of each node data in the tree structure data includes the path from the root node of the tree structure to the node corresponding to the current node data, that is, the path from the root node of the tree structure to the node where the current node data is located. path. It can be understood that the path information of each node data includes the current node where the current node data is located and all its parent nodes, and the position of each node data in the entire tree structure can be represented by the path information. Exemplarily, FIG. 4 is a schematic diagram of a tree structure presented by the tree structure data provided in this embodiment of the present application. As shown in FIG. 4 , the path information of the node data at the node E in the tree structure is: starting from the node A, passing through the node B, and then passing through the node D, and finally reaching the node E. Optionally, the path information consists of a node code and a preset separator, the multiple node codes are separated by the preset separator, and the path information ends with the preset separator. As shown in Fig. 4, the codes of each node in the tree structure are represented by A, B, C, D, F, G, H, I, J and K, and the preset separator can be "-", and the node E The path information of the corresponding node data can be expressed as: "A-B-D-E-".
在本申请实施例中,获取树形结构数据中每个节点数据的路径信息,例如,获取用户输入的树形结构数据中每个节点数据的路径信息。示例性的,获取树形结构数据,从所述树形结构数据中抽取出所述树形结构数据所呈现的树形结构,根据所述树形结构确定对应的树形结构数据中每个节点数据的路径信息。可选的,响应于接收到的对所述路径信息的校正信息,对根据树形结构确定的多个节点数据的路径信息进行校正,这样设置的好处在于,当根据树形结构确定的节点数据的路径信息不准确或存在偏差时,可以根据用户输入的校正信息对路径信息进行校正,有助于后续根据路径信息准确读取对应的节点数据。In this embodiment of the present application, the path information of each node data in the tree structure data is obtained, for example, the path information of each node data in the tree structure data input by the user is obtained. Exemplarily, tree structure data is obtained, a tree structure presented by the tree structure data is extracted from the tree structure data, and each node in the corresponding tree structure data is determined according to the tree structure. Path information for the data. Optionally, in response to the received correction information for the path information, the path information of the plurality of node data determined according to the tree structure is corrected. The advantage of this setting is that when the node data determined according to the tree structure is When the path information of the node is inaccurate or there is a deviation, the path information can be corrected according to the correction information input by the user, which helps to accurately read the corresponding node data according to the path information in the future.
S302、将所述每个节点数据的路径信息及对应的节点数据存储于数据库中。S302. Store the path information of each node data and the corresponding node data in a database.
在本申请实施例中,将树形结构数据中每个节点数据的路径信息及对应的节点数据存储于数据库中,得到树形结构数据库。示例性的,在树形结构数据库中不仅存储有树形结构数据中每个节点数据,还存储有与所述每个节点数据关联或对应的路径信息,当从树形结构数据库中进行数据读取时,可以直接基于路径信息读取对应的节点数据,并基于路径信息快速还原多个节点数据所呈现的树形结构。In the embodiment of the present application, the path information of each node data in the tree structure data and the corresponding node data are stored in the database to obtain the tree structure database. Exemplarily, the tree structure database not only stores the data of each node in the tree structure data, but also stores the path information associated with or corresponding to each node data. When data is read from the tree structure database. When taking time, the corresponding node data can be directly read based on the path information, and the tree structure presented by the multiple node data can be quickly restored based on the path information.
可选的,在将所述每个节点数据的路径信息及对应的节点数据存储于数据库中之后,还包括:接收用户对所述路径信息的调整信息,根据所述调整信息更新所述数据库中的所述路径信息。这样设置的好处在于,可以通过对路径信 息的调整,调整节点数据在整个树形结构中的位置,也即可以灵活对树形结构数据所呈现的树形结构进行调整。可选的,在将所述每个节点数据的路径信息及对应的节点数据存储于数据库中之后,还包括:接收用户对所述路径信息的扩展信息,其中,所述扩展信息中包括增加的目标节点;获取与所述扩展信息中目标节点对应的目标节点数据;基于所述扩展信息更新数据库中的所述路径信息并将所述目标节点数据存储于数据库中。这样设置的好处在于,可以对整个树形结构数据进行扩展,增加了树形结构数据存储的灵活性和可扩展性。Optionally, after storing the path information of each node data and the corresponding node data in the database, the method further includes: receiving user adjustment information on the path information, and updating the database according to the adjustment information. of the path information. The advantage of this setting is that the position of the node data in the entire tree structure can be adjusted by adjusting the path information, that is, the tree structure presented by the tree structure data can be adjusted flexibly. Optionally, after storing the path information of each node data and the corresponding node data in the database, the method further includes: receiving extension information of the path information from the user, wherein the extension information includes the added information. target node; obtain target node data corresponding to the target node in the extended information; update the path information in the database based on the extended information and store the target node data in the database. The advantage of this setting is that the entire tree-structured data can be extended, which increases the flexibility and expansibility of tree-structured data storage.
本申请实施例提供的数据存储方法,获取树形结构数据中每个节点数据的路径信息;其中,所述路径信息用于指示树形结构的根节点到当前节点数据所对应节点的路径,所述树形结构为所述树形结构数据所呈现的结构关系;将所述每个节点数据的路径信息及对应的节点数据存储于数据库中。通过采用上述技术方案,不仅解决基于父级节点编码形式进行递归查询时,由于树形结构数据层级关系的不断增长,查询的时间复杂度和空间复杂度会不断递增,运行效率偏低的技术问题,还增加了树形结构数据存储的灵活性和可扩展性,而且方便数据读取时简单、快速还原树形结构数据关系。In the data storage method provided by the embodiment of the present application, the path information of each node data in the tree structure data is obtained; wherein, the path information is used to indicate the path from the root node of the tree structure to the node corresponding to the current node data, so The tree structure is the structural relationship presented by the tree structure data; the path information of each node data and the corresponding node data are stored in the database. By adopting the above technical solution, not only can the recursive query based on the parent node coding form be solved, but the time complexity and space complexity of the query will continue to increase due to the continuous growth of the hierarchical relationship of the tree structure data, and the technical problem of low operation efficiency will be solved. It also increases the flexibility and scalability of tree-structured data storage, and facilitates simple and fast restoration of tree-structured data relationships when reading data.
在一些实施例中,在将所述每个节点数据的路径信息及对应的节点数据存储于数据库中之前,还包括:获取所述每个节点数据所对应节点的节点编码及节点名称;构建所述节点编码、节点名称及路径信息的对应关系表;将所述每个节点数据的路径信息及对应的节点数据存储于数据库中,包括:将所述节点编码、节点名称及路径信息的对应关系表及对应的节点数据存储于数据库中。示例性的,获取每个节点数据所对应节点的节点编码和节点名称,也即获取树形结构中每个节点的节点编码和节点名称,其中,节点编码和节点名称可以唯一表征树形结构中的每个节点。可选的,可以根据用户输入的信息,确定每个节点数据所对应节点的节点编码和节点名称,也可以根据预先设定的编码规则和命名规则,确定树形结构中每个节点的节点编码和节点名称。构建节点编码、 节点名称及每个节点对应的节点数据的路径信息的对应关系表,示例性的,图4中的树形结构的多个节点的节点编码、节点名称及路径信息的对应关系表如下表所示:In some embodiments, before storing the path information of each node data and the corresponding node data in the database, the method further includes: acquiring the node code and node name of the node corresponding to each node data; Describe the corresponding relationship table of node code, node name and path information; store the path information of each node data and the corresponding node data in the database, including: the corresponding relationship between the node code, node name and path information Tables and corresponding node data are stored in the database. Exemplarily, the node code and node name of the node corresponding to each node data are obtained, that is, the node code and node name of each node in the tree structure are obtained, wherein the node code and node name can uniquely characterize the tree structure. of each node. Optionally, the node code and node name of the node corresponding to each node data can be determined according to the information input by the user, or the node code of each node in the tree structure can be determined according to the preset coding rules and naming rules. and node name. A correspondence table of node codes, node names, and path information of node data corresponding to each node is constructed. Exemplarily, a correspondence table of node codes, node names, and path information of multiple nodes in the tree structure in FIG. 4 As shown in the table below:
节点编码(code)Node code (code) 节点名称(name)Node name (name) 路径信息(path)Path information (path)
AA 节点ANode A A-A-
BB 节点BNodeB A-B-A-B-
CC 节点CNode C A-B-C-A-B-C-
DD 节点DNode D A-B-D-A-B-D-
EE 节点ENode E A-B-D-E-A-B-D-E-
FF 节点FNode F A-B-F-A-B-F-
GG 节点GNode G A-G-A-G-
HH 节点HNode H A-G-H-A-G-H-
II 节点INode I A-G-H-I-A-G-H-I-
JJ 节点JNode J A-J-A-J-
KK 节点KNode K A-J-K-A-J-K-
将节点编码、节点名称及路径信息的对应关系表及对应的节点数据储存于数据库中,可以理解的是,将节点编码、节点名称、路径信息及对应的节点数据以库表的形式存储于数据库中。图5为本申请实施例提供的树形结构数据的存储结构示意图。如图5所示,树形结构的储存结构主要有三个字段组成,节点编码(code),节点名称(name)和路径信息(path),在读取数据的过程中,可以根据路径信息来确定每个节点数据的上下级关系。The corresponding relationship table of node code, node name and path information and the corresponding node data are stored in the database. It can be understood that the node code, node name, path information and corresponding node data are stored in the database in the form of a library table. middle. FIG. 5 is a schematic diagram of a storage structure of tree-structured data provided by an embodiment of the present application. As shown in Figure 5, the storage structure of the tree structure is mainly composed of three fields, node code (code), node name (name) and path information (path). In the process of reading data, it can be determined according to the path information. The superior and inferior relationship of each node data.
在一些实施例中,在将所述每个节点数据的路径信息及对应的节点数据存储于数据库中之后,还包括:获取用户输入的数据查询请求;其中,所述数据 查询请求中包含目标节点路径;遍历所述数据库中的多个节点数据的路径信息,获取与所述数据查询请求中的目标节点路径匹配的目标路径信息;从所述数据库中读取与所述目标路径信息对应的节点数据。In some embodiments, after storing the path information of each node data and the corresponding node data in the database, the method further includes: acquiring a data query request input by a user; wherein the data query request includes a target node path; traverse the path information of multiple node data in the database, and obtain the target path information matching the target node path in the data query request; read the node corresponding to the target path information from the database data.
示例性的,获取用户输入的数据查询请求,其中,数据查询请求中可以包括目标节点路径,可以理解的是目标节点路径为待查询的关键字信息。例如,用户输入的数据查询请求可以为SQL语句,例如,数据查询请求可以为“path like‘A-%’”,即用户想要通过上述数据查询请求查询出A节点下的所有层级的节点对应的节点数据,而不需要在借助递归算法实现数据查询。又示例性的,数据查询请求也可以为“path like‘A-%-%-’”,即用户想要通过上述数据查询请求查询出A节点下的隔层全部子节点对应的节点数据,不必在指定每个节点数据所属层级。遍历数据库中多个节点数据的路径信息,基于模糊匹配原则获取与数据查询请求中的目标节点路径相匹配的目标路径信息。例如,图4中的树形结构的多个节点的节点编码、节点名称及路径信息的对应关系表中,与数据查询请求“path like‘A-%’”匹配的目标路径信息为:A-B-,A-B-C-,A-B-D-,A-B-D-E-,A-B-F-,A-G-,A-G-H-,A-G-H-I-,A-J-及A-J-K-;与数据查询请求“path like‘A-%-%-’”匹配的目标路径信息为:A-B-C-,A-B-D-,A-B-D-E-,A-B-F-,A-G-H-,A-G-H-I-及A-J-K-。从数据库中读取与目标路径信息对应的节点数据,例如,目标路径信息为:A-B-C-,A-B-D-,A-B-D-E-,A-B-F-,A-G-H-,A-G-H-I-及A-J-K-,则从数据库中分别读取节点C处的节点数据,节点D处的节点数据,节点E处的节点数据,节点F处的节点数据,节点H处的节点数据,节点I处的节点数据及节点K处的节点数据。Exemplarily, a data query request input by a user is obtained, wherein the data query request may include a target node path, and it can be understood that the target node path is the keyword information to be queried. For example, the data query request input by the user can be an SQL statement, for example, the data query request can be "path like 'A-%'", that is, the user wants to query the corresponding nodes of all levels under the A node through the above data query request The node data does not need to implement data query with the help of recursive algorithm. Another example, the data query request can also be "path like 'A-%-%-'", that is, if the user wants to query the node data corresponding to all the sub-nodes of the compartment under the A node through the above data query request, there is no need to. Specify the level to which each node data belongs. Traverse the path information of multiple node data in the database, and obtain the target path information matching the target node path in the data query request based on the fuzzy matching principle. For example, in the correspondence table of node codes, node names and path information of multiple nodes in the tree structure in FIG. 4, the target path information matching the data query request "path like 'A-%'" is: A-B- , A-B-C-, A-B-D-, A-B-D-E-, A-B-F-, A-G-, A-G-H-, A-G-H-I-, A-J- and A-J-K-; the target path information matching the data query request "path like 'A-%-%-'" is : A-B-C-, A-B-D-, A-B-D-E-, A-B-F-, A-G-H-, A-G-H-I- and A-J-K-. Read the node data corresponding to the target path information from the database. For example, if the target path information is: A-B-C-, A-B-D-, A-B-D-E-, A-B-F-, A-G-H-, A-G-H-I- and A-J-K-, then read the nodes from the database respectively Node data at C, node data at node D, node data at node E, node data at node F, node data at node H, node data at node I, and node data at node K.
可选的,在从所述数据库中读取与所述目标路径信息对应的节点数据之后,还包括:基于目标路径信息将读取的节点数据还原成树形结构数据,也即基于目标路径信息将读取的多个节点数据放置在树形结构的相应的节点位置,以还原树形结构数据。Optionally, after reading the node data corresponding to the target path information from the database, the method further includes: restoring the read node data into tree structure data based on the target path information, that is, based on the target path information. The read multiple node data is placed in the corresponding node positions of the tree structure to restore the tree structure data.
实施例二Embodiment 2
图6是本申请实施例二提供的一种数据存储方法的流程图,如图6所示,该方法包括如下步骤:FIG. 6 is a flowchart of a data storage method provided in Embodiment 2 of the present application. As shown in FIG. 6 , the method includes the following steps:
S601、获取树形结构数据中每个节点数据的路径信息;其中,路径信息用于指示树形结构的根节点到当前节点数据所对应节点的路径,树形结构为树形结构数据所呈现的结构关系。S601. Obtain the path information of each node data in the tree structure data; wherein, the path information is used to indicate the path from the root node of the tree structure to the node corresponding to the current node data, and the tree structure is presented by the tree structure data. structural relationship.
可选的,所述路径信息由节点编码和预设分隔符组成,多个节点编码之间用所述预设分隔符分隔,所述路径信息以所述预设分隔符结尾。Optionally, the path information consists of a node code and a preset separator, the multiple node codes are separated by the preset separator, and the path information ends with the preset separator.
S602、获取每个节点数据所对应节点的节点编码及节点名称。S602. Obtain the node code and node name of the node corresponding to each node data.
S603、构建节点编码、节点名称及路径信息的对应关系表。S603. Build a correspondence table of node codes, node names, and path information.
S604、将节点编码、节点名称及路径信息的对应关系表及对应的节点数据存储于数据库中。S604. Store the corresponding relationship table of the node code, the node name and the path information and the corresponding node data in the database.
S605、获取用户输入的数据查询请求;其中,数据查询请求中包含目标节点路径。S605. Obtain the data query request input by the user, wherein the data query request includes the target node path.
S606、遍历数据库中的多个节点数据的路径信息,获取与数据查询请求中的目标节点路径匹配的目标路径信息。S606. Traverse the path information of multiple node data in the database, and obtain target path information that matches the target node path in the data query request.
S607、从数据库中读取与目标路径信息对应的节点数据。S607: Read node data corresponding to the target path information from the database.
本申请实施例提供的数据存储方法,不仅解决基于父级节点编码形式进行递归查询时,由于树形结构数据层级关系的不断增长,查询的时间复杂度和空间复杂度会不断递增,运行效率偏低的技术问题,还增加了树形结构数据存储的灵活性和可扩展性,而且方便数据读取时简单、快速还原树形结构数据关系。The data storage method provided by the embodiment of the present application not only solves the problem that when recursive query is performed based on the coding form of the parent node, due to the continuous growth of the hierarchical relationship of tree-structured data, the time complexity and space complexity of the query will continue to increase, and the running efficiency will be biased. It also reduces the technical problems and increases the flexibility and scalability of tree-structured data storage, and facilitates simple and fast restoration of tree-structured data relationships when data is read.
实施例三Embodiment 3
图7是本申请实施例三提供的一种数据存储装置的结构示意图。如图7所示,所述装置包括:路径信息获取模块701及存储模块702,其中:FIG. 7 is a schematic structural diagram of a data storage device according to Embodiment 3 of the present application. As shown in FIG. 7 , the apparatus includes: a path information acquisition module 701 and a storage module 702, wherein:
路径信息获取模块701,设置为获取树形结构数据中每个节点数据的路径信息;其中,所述路径信息用于指示树形结构的根节点到当前节点数据所对应节点的路径,所述树形结构为所述树形结构数据所呈现的结构关系;The path information obtaining module 701 is configured to obtain the path information of each node data in the tree structure data; wherein, the path information is used to indicate the path from the root node of the tree structure to the node corresponding to the current node data, the tree The shape structure is the structural relationship presented by the tree structure data;
存储模块702,设置为将所述每个节点数据的路径信息及对应的节点数据存储于数据库中。The storage module 702 is configured to store the path information of each node data and the corresponding node data in the database.
本申请实施例提供的数据存储装置,获取树形结构数据中每个节点数据的路径信息;其中,所述路径信息用于指示树形结构的根节点到当前节点数据所对应节点的路径,所述树形结构为所述树形结构数据所呈现的结构关系;将所述每个节点数据的路径信息及对应的节点数据存储于数据库中。通过采用上述技术方案,不仅解决基于父级节点编码形式进行递归查询时,由于树形结构数据层级关系的不断增长,查询的时间复杂度和空间复杂度会不断递增,运行效率偏低的技术问题,还增加了树形结构数据存储的灵活性和可扩展性,而且方便数据读取时简单、快速还原树形结构数据关系。The data storage device provided by the embodiment of the present application acquires the path information of each node data in the tree structure data; wherein, the path information is used to indicate the path from the root node of the tree structure to the node corresponding to the current node data, so The tree structure is the structural relationship presented by the tree structure data; the path information of each node data and the corresponding node data are stored in the database. By adopting the above technical solution, not only can the recursive query based on the parent node coding form be solved, but the time complexity and space complexity of the query will continue to increase due to the continuous growth of the hierarchical relationship of the tree structure data, and the technical problem of low operation efficiency will be solved. It also increases the flexibility and scalability of tree-structured data storage, and facilitates simple and fast restoration of tree-structured data relationships when reading data.
可选的,所述路径信息由节点编码和预设分隔符组成,多个节点编码之间用所述预设分隔符分隔,所述路径信息以所述预设分隔符结尾。Optionally, the path information consists of a node code and a preset separator, the multiple node codes are separated by the preset separator, and the path information ends with the preset separator.
可选的,所述装置还包括:Optionally, the device further includes:
节点信息获取模块,设置为在将所述每个节点数据的路径信息及对应的节点数据存储于数据库中之前,获取所述每个节点数据所对应节点的节点编码及节点名称;A node information obtaining module, configured to obtain the node code and node name of the node corresponding to each node data before storing the path information of each node data and the corresponding node data in the database;
对应关系构建模块,设置为构建所述节点编码、节点名称及路径信息的对应关系表;A corresponding relationship building module, configured to construct a corresponding relationship table of the node code, node name and path information;
所述存储模块,设置为:The storage module is set to:
将所述节点编码、节点名称及路径信息的对应关系表及对应的节点数据存储于数据库中。The corresponding relationship table of the node code, the node name and the path information and the corresponding node data are stored in the database.
可选的,所述装置还包括:Optionally, the device further includes:
查询请求获取模块,设置为在将所述每个节点数据的路径信息及对应的节点数据存储于数据库中之后,获取用户输入的数据查询请求;其中,所述数据查询请求中包含目标节点路径;The query request obtaining module is configured to obtain the data query request input by the user after the path information of each node data and the corresponding node data are stored in the database; wherein, the data query request includes the target node path;
目标路径获取模块,设置为遍历所述数据库中的多个节点数据的路径信息,获取与所述查询请求中的目标节点路径匹配的目标路径信息;a target path obtaining module, configured to traverse the path information of a plurality of node data in the database, and obtain target path information matching the target node path in the query request;
节点数据读取模块,设置为从所述数据库中读取与所述目标路径信息对应的节点数据。The node data reading module is configured to read the node data corresponding to the target path information from the database.
实施例四Embodiment 4
本申请实施例四提供一种包含计算机可执行指令的存储介质,所述计算机可执行指令在由计算机处理器执行时实现本申请任意实施例所提供的数据存储方法。The fourth embodiment of the present application provides a storage medium containing computer-executable instructions, where the computer-executable instructions, when executed by a computer processor, implement the data storage method provided by any embodiment of the present application.
存储介质——任何的各种类型的存储器设备或存储设备。术语“存储介质”旨在包括:安装介质,例如只读光盘(Compact Disc Read-Only Memory,CD-ROM)、软盘或磁带装置;计算机系统存储器或随机存取存储器,诸如动态随机存取存储器(Dynamic Random Access Memory,DRAM)、双倍速率随机存取存储器(Double Data Rate Random Access Memory,DDRRAM)、静态随机存取存储器(Static Random Access Memory,SRAM)、扩展数据输出存储器(Extended Data Output RAM,EDORAM),兰巴斯(Rambus)RAM等;非易失性存储器,诸如闪存、磁介质(例如硬盘或光存储);寄存器或其它相似类型的 存储器元件等。存储介质可以还包括其它类型的存储器或其组合。另外,存储介质可以位于程序在其中被执行的第一计算机系统中,或者可以位于不同的第二计算机系统中,第二计算机系统通过网络(诸如因特网)连接到第一计算机系统。第二计算机系统可以提供程序指令给第一计算机用于执行。术语“存储介质”可以包括可以驻留在不同位置中(例如在通过网络连接的不同计算机系统中)的至少两个存储介质。存储介质可以存储可由至少一个处理器执行的程序指令(例如为计算机程序)。storage medium - any of various types of memory devices or storage devices. The term "storage medium" is intended to include: installation media, such as Compact Disc Read-Only Memory (CD-ROM), floppy disks, or tape devices; computer system memory or random access memory, such as dynamic random access memory ( Dynamic Random Access Memory, DRAM), Double Data Rate Random Access Memory (DDRRAM), Static Random Access Memory (Static Random Access Memory, SRAM), Extended Data Output RAM (Extended Data Output RAM, EDORAM), Rambus RAM, etc.; non-volatile memory, such as flash memory, magnetic media (eg, hard disk or optical storage); registers or other similar types of memory elements, and the like. The storage medium may also include other types of memory or combinations thereof. In addition, the storage medium may be located in the first computer system in which the program is executed, or may be located in a second, different computer system connected to the first computer system through a network such as the Internet. The second computer system may provide program instructions to the first computer for execution. The term "storage media" may include at least two storage media that may reside in different locations (eg, in different computer systems connected by a network). The storage medium may store program instructions (eg, a computer program) executable by at least one processor.
本申请实施例所提供的一种包含计算机可执行指令的存储介质,其计算机可执行指令可以执行本申请任意实施例所提供的数据存储方法。An embodiment of the present application provides a storage medium containing computer-executable instructions, and the computer-executable instructions of the storage medium can execute the data storage method provided by any embodiment of the present application.
实施例五Embodiment 5
图8为本申请实施例五提供的一种服务器的结构示意图。图8显示的服务器仅仅是一个示例,不应对本申请实施例的功能和使用范围带来任何限制。如图8所示,本申请实施例五提供的服务器,包括处理器81、存储器82、输入装置83和输出装置84;服务器中处理器81的数量可以是至少一个,图8中以一个处理器81为例;服务器中的处理器81、存储器82、输入装置83和输出装置84可以通过总线或其他方式连接,图8中以通过总线连接为例。FIG. 8 is a schematic structural diagram of a server according to Embodiment 5 of the present application. The server shown in FIG. 8 is only an example, and should not impose any limitations on the functions and scope of use of the embodiments of the present application. As shown in FIG. 8 , the server provided in Embodiment 5 of the present application includes a processor 81, a memory 82, an input device 83, and an output device 84; the number of processors 81 in the server may be at least one, and in FIG. 8, one processor is used Take 81 as an example; the processor 81, the memory 82, the input device 83, and the output device 84 in the server may be connected through a bus or other means, and FIG. 8 takes the connection through a bus as an example.
存储器82作为一种计算机可读存储介质,可设置为存储软件程序、计算机可执行程序以及模块,如本申请实施例中的数据存储方法对应的程序指令/模块(例如,数据存储装置中的路径信息获取模块701及存储模块702)。处理器81通过运行存储在存储器82中的软件程序、指令以及模块,从而执行各种功能应用以及文件处理,例如实现本申请实施例所提供的应用于服务器的数据存储方法。As a computer-readable storage medium, the memory 82 may be configured to store software programs, computer-executable programs, and modules, such as program instructions/modules corresponding to the data storage method in the embodiments of the present application (for example, a path in a data storage device). information acquisition module 701 and storage module 702). The processor 81 executes various functional applications and file processing by running the software programs, instructions, and modules stored in the memory 82, for example, implementing the data storage method applied to the server provided by the embodiments of the present application.
存储器82可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序;存储数据区可存储根据服务器的 使用所创建的数据等。此外,存储器82可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他非易失性固态存储器件。在一些实例中,存储器82可包括相对于处理器81远程设置的存储器,这些远程存储器可以通过网络连接至服务器。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。The memory 82 may mainly include a stored program area and a stored data area, wherein the stored program area may store an operating system, an application program required for at least one function; the stored data area may store data created according to the use of the server, and the like. Additionally, memory 82 may include high speed random access memory, and may also include nonvolatile memory, such as at least one magnetic disk storage device, flash memory device, or other nonvolatile solid state storage device. In some examples, memory 82 may include memory located remotely from processor 81, which may be connected to a server through a network. Examples of such networks include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
输入装置83可设置为接收用户输入的数字或字符信息,以产生与服务器的用户设置以及功能控制有关的键信号输入。输出装置84可包括显示屏等显示设备。The input device 83 may be configured to receive numerical or character information input by the user to generate key signal input related to user setting and function control of the server. The output device 84 may include a display device such as a display screen.
上述实施例中提供的数据存储装置、存储介质及服务器可执行本申请实施例所提供的数据存储方法,具备执行该方法相应的功能模块。未在上述实施例中详尽描述的技术细节,可参见本申请任意实施例所提供的数据存储方法。The data storage device, storage medium, and server provided in the above embodiments can execute the data storage method provided by the embodiment of the present application, and have corresponding functional modules for executing the method. For technical details not described in detail in the foregoing embodiments, reference may be made to the data storage method provided by any embodiment of the present application.

Claims (10)

  1. 一种数据存储方法,包括:A data storage method comprising:
    获取树形结构数据中每个节点数据的路径信息;其中,所述路径信息用于指示树形结构的根节点到当前节点数据所对应节点的路径,所述树形结构为所述树形结构数据所呈现的结构关系;Obtain the path information of each node data in the tree structure data; wherein, the path information is used to indicate the path from the root node of the tree structure to the node corresponding to the current node data, and the tree structure is the tree structure The structural relationships presented by the data;
    将所述每个节点数据的路径信息及对应的节点数据存储于数据库中。The path information of each node data and the corresponding node data are stored in the database.
  2. 根据权利要求1所述的方法,其中,所述路径信息由节点编码和预设分隔符组成,多个节点编码之间用所述预设分隔符分隔,所述路径信息以所述预设分隔符结尾。The method according to claim 1, wherein the path information is composed of a node code and a preset separator, a plurality of node codes are separated by the preset separator, and the path information is separated by the preset separator end of character.
  3. 根据权利要求1所述的方法,在将所述每个节点数据的路径信息及对应的节点数据存储于数据库中之前,还包括:The method according to claim 1, before storing the path information of each node data and the corresponding node data in the database, further comprising:
    获取所述每个节点数据所对应节点的节点编码及节点名称;Obtain the node code and node name of the node corresponding to each node data;
    构建所述节点编码、节点名称及路径信息的对应关系表;constructing the corresponding relationship table of the node code, node name and path information;
    将所述每个节点数据的路径信息及对应的节点数据存储于数据库中,包括:Store the path information of each node data and the corresponding node data in the database, including:
    将所述节点编码、节点名称及路径信息的对应关系表及对应的节点数据存储于数据库中。The corresponding relationship table of the node code, the node name and the path information and the corresponding node data are stored in the database.
  4. 根据权利要求1-3任一所述的方法,在将所述每个节点数据的路径信息及对应的节点数据存储于数据库中之后,还包括:The method according to any one of claims 1-3, after storing the path information of each node data and the corresponding node data in the database, further comprising:
    获取用户输入的数据查询请求;其中,所述数据查询请求中包含目标节点路径;Obtain the data query request input by the user; wherein, the data query request includes the target node path;
    遍历所述数据库中的多个节点数据的路径信息,获取与所述数据查询请求中的目标节点路径匹配的目标路径信息;Traverse the path information of multiple node data in the database, and obtain target path information matching the target node path in the data query request;
    从所述数据库中读取与所述目标路径信息对应的节点数据。The node data corresponding to the target path information is read from the database.
  5. 一种数据存储装置,包括:A data storage device, comprising:
    路径信息获取模块,设置为获取树形结构数据中每个节点数据的路径信息;其中,所述路径信息用于指示树形结构的根节点到当前节点数据所对应节点的路径,所述树形结构为所述树形结构数据所呈现的结构关系;A path information acquisition module, configured to acquire path information of each node data in the tree structure data; wherein, the path information is used to indicate the path from the root node of the tree structure to the node corresponding to the current node data, the tree structure The structure is the structural relationship presented by the tree structure data;
    存储模块,设置为将所述每个节点数据的路径信息及对应的节点数据存储于数据库中。The storage module is configured to store the path information of each node data and the corresponding node data in the database.
  6. 根据权利要求5所述的装置,其中,所述路径信息由节点编码和预设分隔符组成,多个节点编码之间用所述预设分隔符分隔,所述路径信息以所述预设分隔符结尾。The device according to claim 5, wherein the path information is composed of a node code and a preset separator, a plurality of node codes are separated by the preset separator, and the path information is separated by the preset separator end of character.
  7. 根据权利要求5所述的装置,还包括:The apparatus of claim 5, further comprising:
    节点信息获取模块,设置为在将所述每个节点数据的路径信息及对应的节点数据存储于数据库中之前,获取所述每个节点数据所对应节点的节点编码及节点名称;A node information obtaining module, configured to obtain the node code and node name of the node corresponding to each node data before storing the path information of each node data and the corresponding node data in the database;
    对应关系构建模块,设置为构建所述节点编码、节点名称及路径信息的对应关系表;A corresponding relationship building module, configured to construct a corresponding relationship table of the node code, node name and path information;
    所述存储模块,设置为:将所述节点编码、节点名称及路径信息的对应关系表及对应的节点数据存储于数据库中。The storage module is configured to: store the corresponding relationship table of the node code, the node name and the path information and the corresponding node data in the database.
  8. 根据权利要求5-7任一所述的装置,还包括:The device according to any one of claims 5-7, further comprising:
    查询请求获取模块,设置为在将所述每个节点数据的路径信息及对应的节点数据存储于数据库中之后,获取用户输入的数据查询请求;其中,所述数据查询请求中包含目标节点路径;The query request obtaining module is configured to obtain the data query request input by the user after the path information of each node data and the corresponding node data are stored in the database; wherein, the data query request includes the target node path;
    目标路径获取模块,设置为遍历所述数据库中的多个节点数据的路径信息,获取与所述查询请求中的目标节点路径匹配的目标路径信息;a target path obtaining module, configured to traverse the path information of a plurality of node data in the database, and obtain target path information matching the target node path in the query request;
    节点数据读取模块,设置为从所述数据库中读取与所述目标路径信息对应的节点数据。The node data reading module is configured to read the node data corresponding to the target path information from the database.
  9. 一种计算机可读存储介质,所述计算机可读存储介质上存储有计算机程序,所述计算机程序被处理器执行时实现如权利要求1-4中任一所述的数据存储方法。A computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, implements the data storage method according to any one of claims 1-4.
  10. 一种服务器,包括:A server that includes:
    至少一个处理器;at least one processor;
    存储器,设置为存储至少一个程序;a memory, arranged to store at least one program;
    当所述至少一个程序被所述至少一个处理器执行,使得所述至少一个处理器实现如权利要求1-4任一所述的数据存储方法。When the at least one program is executed by the at least one processor, the at least one processor implements the data storage method according to any one of claims 1-4.
PCT/CN2021/108064 2020-12-18 2021-07-23 Data storage method and apparatus, and storage medium and server WO2022127114A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011502922.4A CN112632065A (en) 2020-12-18 2020-12-18 Data storage method and device, storage medium and server
CN202011502922.4 2020-12-18

Publications (1)

Publication Number Publication Date
WO2022127114A1 true WO2022127114A1 (en) 2022-06-23

Family

ID=75317613

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/108064 WO2022127114A1 (en) 2020-12-18 2021-07-23 Data storage method and apparatus, and storage medium and server

Country Status (2)

Country Link
CN (1) CN112632065A (en)
WO (1) WO2022127114A1 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112632065A (en) * 2020-12-18 2021-04-09 北京锐安科技有限公司 Data storage method and device, storage medium and server
CN113553330A (en) * 2021-07-28 2021-10-26 上海华瑞银行股份有限公司 Method, device and electronic equipment for realizing service data self-adaptive display
CN113704294A (en) * 2021-08-17 2021-11-26 北京达佳互联信息技术有限公司 Data processing method and device, electronic equipment and storage medium
CN116108235B (en) * 2023-02-20 2023-11-10 上海安博通信息科技有限公司 Path acquisition method and device for tree structure and processing equipment

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101655871A (en) * 2009-09-25 2010-02-24 金蝶软件(中国)有限公司 Method and device for storing and inquiring data
US20130151565A1 (en) * 2011-12-08 2013-06-13 Xerox Corporation Arithmetic node encoding for tree structures
CN103279544A (en) * 2013-06-05 2013-09-04 中国电子科技集团公司第十五研究所 Method and device for storing and inquiring tree structure data in relational database
CN103853773A (en) * 2012-12-04 2014-06-11 厦门亿联网络技术股份有限公司 Searching method of tree data structure of Mysql database
US20150142796A1 (en) * 2013-11-15 2015-05-21 Microsoft Corporation Processing search queries using a data structure
CN108681603A (en) * 2018-05-22 2018-10-19 福建天泉教育科技有限公司 The method of fast search tree structure data, storage medium in database
CN112632065A (en) * 2020-12-18 2021-04-09 北京锐安科技有限公司 Data storage method and device, storage medium and server

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7403941B2 (en) * 2004-04-23 2008-07-22 Novauris Technologies Ltd. System, method and technique for searching structured databases

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101655871A (en) * 2009-09-25 2010-02-24 金蝶软件(中国)有限公司 Method and device for storing and inquiring data
US20130151565A1 (en) * 2011-12-08 2013-06-13 Xerox Corporation Arithmetic node encoding for tree structures
CN103853773A (en) * 2012-12-04 2014-06-11 厦门亿联网络技术股份有限公司 Searching method of tree data structure of Mysql database
CN103279544A (en) * 2013-06-05 2013-09-04 中国电子科技集团公司第十五研究所 Method and device for storing and inquiring tree structure data in relational database
US20150142796A1 (en) * 2013-11-15 2015-05-21 Microsoft Corporation Processing search queries using a data structure
CN108681603A (en) * 2018-05-22 2018-10-19 福建天泉教育科技有限公司 The method of fast search tree structure data, storage medium in database
CN112632065A (en) * 2020-12-18 2021-04-09 北京锐安科技有限公司 Data storage method and device, storage medium and server

Also Published As

Publication number Publication date
CN112632065A (en) 2021-04-09

Similar Documents

Publication Publication Date Title
WO2022127114A1 (en) Data storage method and apparatus, and storage medium and server
AU2017269108B2 (en) Optimizing read and write operations in object schema-based application programming interfaces (APIS)
US9576011B2 (en) Indexing hierarchical data
JP7410919B2 (en) Generation, access, and display of lineage metadata
US9378233B2 (en) For all entries processing
US9244838B2 (en) System, method, and computer-readable medium for grouping database level object access counts per processing module in a parallel processing system
CN104123374A (en) Method and device for aggregate query in distributed databases
US10437853B2 (en) Tracking data replication and discrepancies in incremental data audits
US10963442B2 (en) Derivation of hierarchy indexes
US20100235344A1 (en) Mechanism for utilizing partitioning pruning techniques for xml indexes
US9659023B2 (en) Maintaining and using a cache of child-to-parent mappings in a content-addressable storage system
US11449550B2 (en) Ad-hoc graph definition
CN111897824A (en) Data operation method, device, equipment and storage medium
US20080294673A1 (en) Data transfer and storage based on meta-data
CN110109951B (en) Correlation query method, database application system and server
de Souza Baptista et al. NoSQL geographic databases: an overview
US10817507B2 (en) Document store export/import
US11379485B2 (en) Inferred predicates for query optimization
US11556532B2 (en) Hash trie based optimization of database operations
CN110019518B (en) Data processing method and device
US10353920B2 (en) Efficient mirror data re-sync
Chellappan et al. MongoDB features and installation
US20180365306A1 (en) System and Method for Query Optimized Modeling
US11157500B2 (en) Determination of query operator execution location
US20210357399A1 (en) Method of processing database and information processing apparatus

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21905047

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21905047

Country of ref document: EP

Kind code of ref document: A1