CN108733668B - Method and device for querying data - Google Patents

Method and device for querying data Download PDF

Info

Publication number
CN108733668B
CN108733668B CN201710242321.6A CN201710242321A CN108733668B CN 108733668 B CN108733668 B CN 108733668B CN 201710242321 A CN201710242321 A CN 201710242321A CN 108733668 B CN108733668 B CN 108733668B
Authority
CN
China
Prior art keywords
data
node
target
level
hierarchical
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.)
Active
Application number
CN201710242321.6A
Other languages
Chinese (zh)
Other versions
CN108733668A (en
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.)
Baidu Online Network Technology Beijing Co Ltd
Original Assignee
Baidu Online Network Technology Beijing 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 Baidu Online Network Technology Beijing Co Ltd filed Critical Baidu Online Network Technology Beijing Co Ltd
Priority to CN201710242321.6A priority Critical patent/CN108733668B/en
Publication of CN108733668A publication Critical patent/CN108733668A/en
Application granted granted Critical
Publication of CN108733668B publication Critical patent/CN108733668B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

Methods and apparatus for querying data are disclosed. One embodiment of the method comprises: receiving a data query request sent by a user terminal, wherein the data query request comprises a user identifier, a field name and a data version number; determining whether target level data which contains a data identifier matched with the user identifier and contains a data version number identical to the data version number contained in the data query request exists in a level data set, wherein the level data set is stored in a memory in advance, and each level data in the level data set is provided with the data identifier and the data version number; in response to determining that the target hierarchical data exists in the set of hierarchical data, data requested by the data query request relating to the field indicated by the field name is determined based on the target hierarchical data, and the data is returned to the user terminal. The embodiment improves the effectiveness of data query.

Description

Method and device for querying data
Technical Field
The present application relates to the field of computer technologies, and in particular, to the field of internet technologies, and in particular, to a method and an apparatus for querying data.
Background
Hierarchical data is data that contains multiple hierarchies (e.g., parent hierarchy, child hierarchy), with a definite hierarchy. The hierarchical data may be, for example, data having a tree-shaped storage structure. For example, the hierarchical data for storing the item information includes three levels, a first level of the hierarchical data may include item identifiers of a first class to which the item belongs, a second level may include item identifiers of sub-classes of the first class, and a third level may include item identifiers of items belonging to each sub-class, the third level being a last level of the hierarchical data. Herein, the first hierarchy may be referred to as a parent hierarchy of the second hierarchy, and the second hierarchy may be referred to as a child hierarchy of the first hierarchy; the second level can be referred to as a parent level of the third level, and the third level can be referred to as a child level of the second level.
Data query systems in the prior art typically query a set or number of identifiers in a child hierarchy that are associated with an identifier located in a parent hierarchy based on the identifier, typically without regard to whether the stored hierarchy data has expired, so that the data returned to the user may be expired data.
Disclosure of Invention
It is an object of the present application to propose an improved method and apparatus for querying data to solve the technical problems mentioned in the background section above.
In a first aspect, an embodiment of the present application provides a method for querying data, where the method includes: receiving a data query request sent by a user terminal, wherein the data query request comprises a user identifier, a field name and a data version number; determining whether target level data which comprises a data identifier matched with the user identifier and comprises a data version number identical to the data version number contained in the data query request exists in a level data set, wherein the level data set is stored in a memory in advance, and each level data in the level data set is provided with the data identifier and the data version number; and in response to determining that the target hierarchy data exists in the hierarchy data set, determining data related to the field indicated by the field name requested by the data query request based on the target hierarchy data, and returning the data to the user terminal.
In some embodiments, for each hierarchical data in the hierarchical data set, each hierarchy of the hierarchical data includes at least one data node provided with a node identification; for each level in the level data that is not the last level, for each data node in the level, the data node comprises at least one data node in a level next to the level; each data node in the last hierarchy is a leaf node, and for each data node included in a hierarchy above the last hierarchy, the data node stores the leaf node number of the included leaf node.
In some embodiments, the data query request further includes a request type and a query condition, where the request type is any one of the following: recording inquiry and quantity inquiry; and the determining, based on the target hierarchy data, data related to the field indicated by the field name requested by the data query request includes: and if the request type is record query, searching the data under the field meeting the query condition in the target level data.
In some embodiments, when the request type is a record query, the data query request further includes a data return starting value and a data number; and if the request type is record query, searching the data under the field meeting the query condition in the target level data, including: if the field name is used for representing data contained in leaf nodes, determining target data nodes meeting the query condition in a level above the last level of the target level data, and generating a target data node sequence; determining a first target data node to which a target leaf node indicated by the data return starting value belongs in the target data node sequence based on the leaf node number stored in the target data node sequence; and traversing leaf nodes included in the first target data node and/or leaf nodes included in data nodes in the sequence of the target data nodes, which are sequentially inferior to the first target data node, from the target leaf node in sequence until the data under the fields with the number of data are found, and returning the found data to the user terminal.
In some embodiments, the determining, based on the target hierarchy data, data requested by the data query request and related to the field indicated by the field name further includes: if the request type is a quantity query and the field name is used for representing the quantity of leaf nodes, determining data nodes meeting the query condition in data nodes included in a level immediately above the last level of the target level data to generate a data node set; and if the data node set comprises one data node, returning the leaf node number stored by the data node to the user terminal.
In some embodiments, the determining, based on the target hierarchy data, data requested by the data query request and related to the field indicated by the field name further includes: and if the data node set comprises at least two data nodes, summing the leaf node numbers respectively stored by each data node in the data node set, and returning the numerical value obtained by summation to the user terminal.
In some embodiments, for each hierarchical data in the hierarchical data set, the node identifications of the leaf nodes belonging to the hierarchical data are stored by a bitmap method.
In some embodiments, the above method further comprises: and in response to determining that the target hierarchical data does not exist in the hierarchical data set, forwarding the data query request to a connected data storage server, receiving the data requested by the data query request from the data storage server, and returning the received data to the user terminal.
In some embodiments, the above method further comprises: and returning data invalidation prompt information to the user terminal in response to determining that the target hierarchy data does not exist in the hierarchy data set.
In a second aspect, an embodiment of the present application provides an apparatus for querying data, where the apparatus includes: the device comprises a receiving unit, a sending unit and a receiving unit, wherein the receiving unit is configured to receive a data query request sent by a user terminal, and the data query request comprises a user identifier, a field name and a data version number; a determining unit, configured to determine whether there is target level data in a level data set, where the target level data includes a data identifier that matches the user identifier and includes a data version number that is the same as the data version number included in the data query request, and the level data set is stored in a memory in advance, and each level data in the level data set is provided with a data identifier and a data version number; and a data returning unit configured to, in response to determining that the target hierarchical data exists in the hierarchical data set, determine, based on the target hierarchical data, data related to a field indicated by the field name requested by the data query request, and return the data to the user terminal.
In some embodiments, for each hierarchical data in the hierarchical data set, each hierarchy of the hierarchical data includes at least one data node provided with a node identification; for each level in the level data that is not the last level, for each data node in the level, the data node comprises at least one data node in a level next to the level; each data node in the last hierarchy is a leaf node, and for each data node included in a hierarchy above the last hierarchy, the data node stores the leaf node number of the included leaf node.
In some embodiments, the data query request further includes a request type and a query condition, where the request type is any one of the following: recording inquiry and quantity inquiry; and the data return unit includes: and the searching subunit is configured to search, if the request type is record query, data under the field which meets the query condition in the target level data.
In some embodiments, when the request type is a record query, the data query request further includes a data return starting value and a data number; and the searching subunit comprises: a search module configured to determine, if the field name is used to represent data included in a leaf node, a target data node that satisfies the query condition in a level immediately preceding a last level of the target level data, and generate a target data node sequence; determining a first target data node to which a target leaf node indicated by the data return starting value belongs in the target data node sequence based on the leaf node number stored in the target data node sequence; and traversing leaf nodes included in the first target data node and/or leaf nodes included in data nodes in the sequence of the target data nodes, which are sequentially inferior to the first target data node, from the target leaf node in sequence until the data under the fields with the number of data are found, and returning the found data to the user terminal.
In some embodiments, the data return unit further includes: a first data returning subunit, configured to determine, if the request type is a quantity query and the field name is used to represent the quantity of leaf nodes, a data node that satisfies the query condition among data nodes included in a level immediately above a last level of the target level data, so as to generate a data node set; and if the data node set comprises one data node, returning the leaf node number stored by the data node to the user terminal.
In some embodiments, the data return unit further includes: and a second data return subunit, configured to sum, if the data node set includes at least two data nodes, the leaf node numbers respectively stored in the data nodes in the data node set, and return a value obtained by the summation to the user terminal.
In some embodiments, for each hierarchical data in the hierarchical data set, the node identifications of the leaf nodes belonging to the hierarchical data are stored by a bitmap method.
In some embodiments, the above apparatus further comprises: and a first data returning unit, configured to, in response to determining that the target hierarchical data does not exist in the hierarchical data set, forward the data query request to a connected data storage server, so as to receive the data requested by the data query request from the data storage server, and return the received data to the user terminal.
In some embodiments, the above apparatus further comprises: and the second data returning unit is configured to return data invalidation prompting information to the user terminal in response to determining that the target hierarchical data does not exist in the hierarchical data set.
In a third aspect, an embodiment of the present application provides a server, where the server includes: one or more processors; storage means for storing one or more programs; when the one or more programs are executed by the one or more processors, the one or more processors are caused to implement the method as described in any implementation manner of the first aspect.
In a fourth aspect, the present application provides a computer-readable storage medium, on which a computer program is stored, where the computer program is configured to, when executed by a processor, implement the method described in any implementation manner of the first aspect.
According to the method and the device for querying data provided by the embodiment of the application, after a data query request which is sent by a user terminal and contains a user identifier, a field name and a data version number is received, whether target hierarchical data which contains the data identifier matched with the user identifier and contains the data version number identical to the data version number contained in the data query request exists in a hierarchical data set or not is determined, so that whether effective data aiming at a user indicated by the user terminal exists in a memory or not is determined. And then, after determining that the target hierarchy data exists in the hierarchy data set, determining data related to the field indicated by the field name requested by the data query request based on the target hierarchy data, and returning the data to the user terminal. Therefore, the determination of the target level data is effectively utilized, the data returned to the user terminal is avoided to be invalid data, and the effectiveness of data query is improved.
Drawings
Other features, objects and advantages of the present application will become more apparent upon reading of the following detailed description of non-limiting embodiments thereof, made with reference to the accompanying drawings in which:
FIG. 1 is an exemplary system architecture diagram in which the present application may be applied;
FIG. 2 is a flow diagram for one embodiment of a method for querying data, according to the present application;
FIG. 3 is a schematic diagram of a hierarchy of data comprising three levels;
FIG. 4 is a schematic diagram of an application scenario corresponding to the embodiment shown in FIG. 2;
FIG. 5 is a flow diagram of yet another embodiment of a method for querying data according to the present application;
FIG. 6 is a schematic block diagram illustrating one embodiment of an apparatus for querying data according to the present application;
FIG. 7 is a block diagram of a computer system suitable for use in implementing a server according to embodiments of the present application.
Detailed Description
The present application will be described in further detail with reference to the following drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the relevant invention and not restrictive of the invention. It should be noted that, for convenience of description, only the portions related to the related invention are shown in the drawings.
It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict. The present application will be described in detail below with reference to the embodiments with reference to the attached drawings.
Fig. 1 shows an exemplary system architecture 100 to which embodiments of the method for querying data or the apparatus for querying data of the present application may be applied.
As shown in fig. 1, the system architecture 100 may include terminal devices 101, 102, 103, a network 104, and a server 105. The network 104 serves as a medium for providing communication links between the terminal devices 101, 102, 103 and the server 105. Network 104 may include various connection types, such as wired, wireless communication links, or fiber optic cables, to name a few.
The user may use the terminal devices 101, 102, 103 to interact with the server 105 via the network 104 to send data query requests or to receive data or the like. The terminal devices 101, 102, 103 may have various communication client applications installed thereon, such as a web browser application, a data query application, and the like.
The terminal devices 101, 102, 103 may be various electronic devices having a display screen, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like.
The server 105 may be a server that provides various services, for example, processes a data query request sent by the terminal devices 101, 102, 103, and returns a processing result (e.g., data requested by the data query request) to the terminal device.
It should be noted that the method for querying data provided by the embodiment of the present application is generally performed by the server 105, and accordingly, the apparatus for querying data is generally disposed in the server 105.
It should be understood that the number of terminal devices, networks, and servers in fig. 1 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
With continued reference to FIG. 2, a flow 200 of one embodiment of a method for querying data in accordance with the present application is shown. The method for querying data comprises the following steps:
step 201, receiving a data query request sent by a user terminal.
In this embodiment, the electronic device (for example, the server 105 shown in fig. 1) on which the method for querying data operates may receive a data query request sent by a user terminal (for example, the terminal devices 101, 102, 103 shown in fig. 1) through a wired connection manner or a wireless connection manner. The data query request may include a user identifier, a field name, and a data version number. Here, the user identity may be a user identity of a user to which the user terminal belongs. The user identification may include letters, numbers, etc. The field name is a field name of a field in which data requested by the data query request is located or a field name of a field related to the data, and for example, when the data requested by the data query request is an item identification or an item identification number, the field name may be a field name of an item identification field. The field names can be expressed in English or Chinese. For example, a field name "article identification" expressed in chinese, and a field name "GoodsID" corresponding to the "article identification" expressed in english. The data version number is a version number of hierarchical data (e.g., data having a tree storage structure) associated with the data requested by the data query request.
Step 202, determining whether target level data which contains a data identification matched with the user identification and has the same data version number as the data version number contained in the data query request exists in the level data set.
In this embodiment, after receiving the data query request, the electronic device may determine whether there is target level data in a level data set pre-stored in a memory, where the target level data includes a data identifier that matches the user identifier and includes a data version number that is the same as the data version number included in the data query request. Each hierarchical data in the hierarchical data set is provided with a data identifier and a data version number. Here, for each hierarchical data in the hierarchical data set, the data identifier of the hierarchical data may be a user identifier of a user to which the hierarchical data belongs, or may be automatically set by the electronic device. The data identifier of the hierarchical data and the user identifier of the user to which the hierarchical data belongs may be stored in a correspondence list in advance in an associated manner, and the correspondence list may be stored locally in the electronic device. If the data identifier of each hierarchical data in the hierarchical data set is the user identifier of the user to which the hierarchical data belongs, if the data identifier of the hierarchical data is the same as the user identifier included in the data query request, the electronic device may determine that the data identifier of the hierarchical data matches the user identifier included in the data query request.
Optionally, if the data identifier of each hierarchical data in the hierarchical data set is not the user identifier of the user to which the hierarchical data belongs, the electronic device may determine whether a data identifier matching the user identifier included in the data query request exists in the data identifiers of each hierarchical data in the hierarchical data set by reading the correspondence list stored in advance locally.
In some optional implementations of this embodiment, for each hierarchical data in the hierarchical data set, each hierarchy of the hierarchical data may include at least one data node provided with a node identifier; for each level in the level data that is not the last level, for each data node in the level, the data node comprises at least one data node in a level next to the level; each data node in the last hierarchy is a leaf node, and for each data node included in a hierarchy above the last hierarchy, the data node stores the leaf node number of the included leaf node. Turning to fig. 3, fig. 3 shows a schematic diagram of a hierarchy of data comprising three levels. In fig. 3, the data nodes 301, 302 are data nodes located at a first hierarchical level. The data nodes 3011, 3021 are data nodes located at the second hierarchical level. The data node 3011 belongs to the data node 301 and is a child node of the data node 301. Data node 3021 belongs to data node 302 and is a child node of data node 302. The data nodes 30111, 30112, 30211, 30212 are data nodes located at the third hierarchical level (i.e., the last hierarchical level of the hierarchical data), and the data nodes 30111, 30112 belong to the data node 3011 and are child nodes of the data node 3011. Data nodes 30211 and 30212 belong to the data node 3021 and are child nodes of the data node 3021. The data nodes 30111, 30112, 30211, 30212 may be referred to as leaf nodes. It is noted that a leaf node may be understood as a data node without children.
In some optional implementations of this embodiment, for each hierarchical data in the hierarchical data set, the node identifiers of the leaf nodes belonging to the hierarchical data may be stored by bitmap (bitmap). Here, the bitmap method can store a certain state with each bit, and is suitable for large-scale data, but the data states are not many. For example, the electronic device may preset a base number (e.g. 1024), set an array with a length of a first preset value (e.g. 1000) and a data type of basic integer (int), and assuming that the array includes 1000 elements, the index number of the element included in the array is from 0 to 999, if a node of a leaf node is identified as "1025", the electronic device may subtract the base number 1024 from 1025 to obtain a value of 1, and the electronic device may set the value of the element with the index number of 1 in the array to 1. Therefore, when large-scale data is stored, a large amount of memory space can be saved by storing the data through the bitmap method, and the memory load can be greatly reduced.
In some optional implementations of the present embodiment, the hierarchical data in the hierarchical data set may be updated (e.g., added, deleted, changed). The electronic device may be connected to a data storage server (not shown in fig. 1) in a remote communication manner, and the hierarchical data included in the hierarchical data set may be data in the data storage server. Here, the electronic device or the data storage server may be a server supporting a data synchronization function, and when there is a change in data in the data storage server, the data storage server or the electronic device may automatically synchronize the changed data to the hierarchical data set so as to ensure consistency between the hierarchical data set and the data in the data storage server. It should be noted that, when there is a change in the data in each hierarchical level data, the data version number of the hierarchical level data is changed accordingly, for example, the data in the hierarchical level data is changed once, and the data version number of the hierarchical level data is increased by 1. When there is a change in the data storage server, the data storage server or the electronic device may feed back the latest data version number of the hierarchical data in which the changed data is located to the user to whom the hierarchical data belongs.
And step 203, in response to determining that the target hierarchy data exists in the hierarchy data set, determining data related to the field indicated by the field name requested by the data query request based on the target hierarchy data, and returning the data to the user terminal.
In this embodiment, in response to determining that the target hierarchical data exists in the hierarchical data set in step 202, the electronic device may determine, based on the target hierarchical data, data related to a field indicated by the field name requested by the data query request, and return the data to the user terminal. For example, the last level of the target level data includes item identifiers "001", "002" and "003", the field is named "item identifier", and the electronic device may search for data under the item identifier field in the target level data by using a Depth-First traversal (Depth-First Traversa) algorithm, and return the searched data (e.g., "001", "002" and "003") to the user terminal.
For another example, the electronic device may count the number of the data in the item identifier field, and return the number to the user terminal as the data related to the item identifier field.
It should be noted that the depth-first traversal algorithm is a classic algorithm in graph theory, a corresponding topology sorting table of the target graph can be generated by using the depth-first traversal algorithm, and many related graph theory problems, such as a maximum path problem, can be conveniently solved by using the topology sorting table. Since the depth-first traversal algorithm is a well-known technique widely studied and applied at present, it will not be described in detail here.
In some optional implementation manners of this embodiment, the data query request may further include a request type and a query condition, where the request type is any one of the following: and recording the query and the quantity query. If the request type is record query, the electronic device may search the target hierarchy data for data under a field indicated by a field name included in the data query request, which satisfies the query condition. Wherein, the record query may refer to a field value (e.g. item identification "10000", "10001", "10002", etc.) under a specified field (e.g. item identification field) of the query; a quantity query may refer to the number of field values under a specified field of the query.
Here, the query condition may define a range of data requested by the data query request. As an example, the target hierarchy data includes three hierarchies, a first hierarchy includes category identifiers of primary categories (e.g., "computer", "appliance") to which a plurality of items (e.g., laptop computer, microwave oven) respectively belong, a second hierarchy includes category identifiers of secondary categories (e.g., "laptop computer", "kitchen appliance") to which the plurality of items respectively belong, and a third hierarchy includes item identifiers of the plurality of items, and assuming that the field is named as "item identifier", the query condition may be that the item identifier is greater than a preset value (e.g., greater than 1000), the query condition may be that the category identifiers of the secondary categories are within a preset value range, the query condition may be that the category identifiers of the primary categories are equal to a second preset value, and so on. As to the content included in the query condition, the preset value, and the second preset value, this embodiment does not limit the content in this respect. The preset value and the second preset value can be modified according to actual needs.
In some optional implementation manners of this embodiment, if the electronic device determines that the target hierarchical data does not exist in the hierarchical data set, the electronic device may forward the data query request to the data storage server, so as to receive data requested by the data query request from the data storage server, and return the data to the user terminal.
In some optional implementation manners of this embodiment, if the electronic device determines that the target hierarchical data does not exist in the hierarchical data set, the electronic device may further return a data invalidation notification message to the user terminal.
With continued reference to fig. 4, fig. 4 is a schematic diagram of an application scenario of the method for querying data according to the present embodiment. In the application scenario of fig. 4, a user first initiates a data query request 403 to a server 402 through a user terminal 401, wherein the data query request 403 includes a user identifier "001", a field name "item identifier" and a data version number "10". Then, the server 402 may compare the user identifier "001" and the data version number "10" with the data identifier and the data version number of each hierarchical data in the hierarchical data set 404 stored in the memory in advance, and determine a target hierarchical data 4041 in which the data identifier "001" is matched with the user identifier "001" and the data version number "10" is the same as the data version number "10" included in the data query request 403, assuming that the target hierarchical data 4041 includes the item identifiers "10000", "10001", and "10002". Finally, the server 402 may traverse the data in the target hierarchy data 4041 by using a depth-first traversal algorithm, find out the data 40411 under the item identification field indicated by the field name "item identification" requested by the data query request 403, i.e., the item identifications "10000", "10001", "10002", and the server 402 may return the found item identifications "10000", "10001", "10002" to the user terminal 401.
The method provided by the embodiment of the application avoids that the data returned to the user terminal is invalid data by determining the target level data, thereby improving the validity of data query.
With further reference to FIG. 5, a flow 500 of yet another embodiment of a method for querying data is illustrated. The process 500 of the method for querying data includes the following steps:
step 501, receiving a data query request sent by a user terminal.
In this embodiment, the electronic device (for example, the server 105 shown in fig. 1) on which the method for querying data operates may receive a data query request sent by a user terminal (for example, the terminal devices 101, 102, 103 shown in fig. 1) through a wired connection manner or a wireless connection manner. The data query request may include a user identifier, a field name, a data version number, a request type, a query condition, a data return starting value, and a data number. Here, for the explanation of the user identifier, the field name, the data version number, the request type, and the query condition, reference may be made to the related descriptions in step 201 and step 203, respectively, and no further description is given here. It should be noted that the data return start value and the data number may be expressed as data starting from the data of the first data return start value in the data in the field indicated by the field name included in the data query request, which satisfies the query condition, and returning to the user terminal until the data number is continuously returned. For example, the data return starting value is 10000, the number of data is 30, the field name included in the data query request is "item id", and the electronic device finds 11000 pieces of data under the item id indicated by the field name "item id" satisfying the query condition, so that the electronic device can return to the user terminal starting from the 10000 th piece of data of the 11000 pieces of data until 30 pieces of data are continuously returned.
Step 502, determining whether target level data which contains a data identification matched with the user identification and has the same data version number as the data version number contained in the data query request exists in the level data set.
In this embodiment, the hierarchical data set may be stored in the memory of the electronic device in advance, and each hierarchical data in the hierarchical data set may be provided with a data identifier and a data version number. For each hierarchical data in the set of hierarchical data, each hierarchy of the hierarchical data may include at least one data node provided with a node identification; for each level in the level data that is not the last level, for each data node in the level, the data node comprises at least one data node in a level next to the level; each data node in the last hierarchy is a leaf node, and for each data node included in a hierarchy above the last hierarchy, the data node stores the leaf node number of the included leaf node. Here, the method for determining the target level data may refer to the related description in step 202, and is not described herein again.
Here, if the electronic device determines that the target hierarchical data exists in the hierarchical data set and the request type is a record query, the electronic device may perform step 503 and step 505. If the electronic device determines that the target hierarchical data exists in the hierarchical data set and the request type is a quantity query, the electronic device may perform steps 506 and 507, or perform steps 506 and 508.
Step 503, if the field name is used to represent the data included in the leaf node, determining a target data node meeting the query condition in a level above the last level of the target level data, and generating a target data node sequence.
In this embodiment, if the field name included in the data query request is used to characterize data included in a leaf node (for example, a node identifier of the leaf node), the electronic device may determine a target data node that satisfies the query condition in a level immediately above a last level of the target level data, and generate a target data node sequence. As an example, the data query request includes a field name "item id", and the query condition is that the item id of the secondary item is 10 to 12 (including 10 and 12). The target level data comprises three levels, wherein the first level comprises a plurality of data nodes for representing a first level category, the second level comprises a plurality of data nodes for representing a second level category, the third level comprises a plurality of data nodes (namely leaf nodes) for representing item information, and the node identification of each data node in each level is the category identification of the category represented by the data node or the item identification of the item indicated by the represented item information. The electronic device may traverse the data node in the first hierarchical level and the data node belonging to the data node in the second hierarchical level to determine the target data nodes A, B and C with node identifications "10", "11", and "12", respectively, in the second hierarchical level, and generate the target data node sequence P containing the target data nodes A, B and C in this order.
Step 504, based on the number of leaf nodes stored in the target data node sequence, determining a first target data node to which the target leaf node indicated by the data return starting value belongs in the target data node sequence.
In this embodiment, after the target data node sequence is generated, the electronic device may determine, in the target data node sequence, a first target data node to which a target leaf node indicated by the data return start value belongs, based on the number of leaf nodes stored in the target data node sequence. Continuing with the example in step 503, assuming that the data return starting value is 10000, the number of data is 30, the number of leaf nodes stored by the target data node a is 5000, the number of leaf nodes stored by the target data node B is 4000, and the number of leaf nodes stored by the target data node C is 6000, the electronic device may determine, in the target data node sequence P, a first target data node to which the target leaf node D indicated by the data return starting value 10000 belongs, that is, the target data node C, by accumulating 5000 and 4000 and comparing with the data return starting value 10000. The target leaf node D is the 1000 th leaf node in the target data node C.
And 505, starting from the target leaf node, sequentially traversing the leaf nodes included in the first target data node and/or the leaf nodes included in the data nodes in the sequence of the target data nodes, which are in the order of the first target data node, until the data in the field indicated by the field name included in the data number data query request is found, and returning the found data to the user terminal.
In this embodiment, after determining the first target data node to which the target leaf node belongs, the electronic device may sequentially traverse, from the target leaf node, the leaf node included in the first target data node and/or the leaf node included in the data node in the sequence of the target data nodes that is sequentially next to the first target data node, until the data number (that is, the data in the field indicated by the field name included in the data query request) is found. Continuing with the example in step 504 as an example, the electronic device may sequentially traverse leaf nodes included in the first target data node from the target leaf node D until 30 leaf nodes are traversed, where the electronic device may record a node identifier of each leaf node in a memory or a cache when traversing each leaf node. Here, the electronic device may return the found data to the user terminal in the form of, for example, text or picture.
In step 506, if the request type is a quantity query and the field name is used for characterizing the quantity of leaf nodes, data nodes meeting query conditions are determined from data nodes included in a level immediately above the last level of the target level data, so as to generate a data node set.
In this embodiment, if the request type is a quantity query, and a field name included in the data query request is used to represent the quantity of leaf nodes, for example, the field name is "quantity of leaf nodes" or "quantity of leaf node identifiers", and the like, the electronic device may determine, from among data nodes included in a level immediately preceding the last level of the target level data, a data node that satisfies the query condition, so as to generate a data node set. As an example, if the query condition is that the class identifier of the secondary class is greater than 100 and less than 103, the target hierarchy data includes 3 hierarchies, the second hierarchy includes a plurality of data nodes for representing different secondary classes, and the node identifier of the data node is the class identifier of the class represented by the data node, the electronic device may determine, from the data nodes included in the second hierarchy, a data node A, B whose node identifiers respectively satisfy the query condition are 101 and 102, and the electronic device may generate a data node set Q including a data node a and a data node B.
Step 507, if the data node set includes one data node, returning the leaf node number stored in the data node to the user terminal.
In this embodiment, if the data node set includes one data node, the electronic device may return the number of leaf nodes stored in the data node to the user terminal.
Step 508, if the data node set includes at least two data nodes, summing up the leaf node numbers respectively stored by each data node in the data node set, and returning the summed values to the user terminal.
In this embodiment, if the data node set includes at least two data nodes, the electronic device may sum the leaf node numbers stored in the data nodes in the data node set, and return the summed value to the user terminal. Taking the example in step 506 as an example, assuming that the number of leaf nodes stored by the data node A, B in the data node set Q is 5000 and 4000, respectively, the electronic device may sum 5000 and 4000 to obtain a value 9000, and the electronic device may return the value 9000 to the user terminal.
As can be seen from fig. 5, compared with the corresponding embodiment of fig. 2, the flow 500 of the method for querying data in the present embodiment highlights the step of expanding the data query. Therefore, according to the scheme described in the embodiment, the data can be quickly skipped through the number of the leaf nodes stored in advance, and the data query efficiency is greatly improved.
With further reference to fig. 6, as an implementation of the methods shown in the above-mentioned figures, the present application provides an embodiment of an apparatus for querying data, where the embodiment of the apparatus corresponds to the embodiment of the method shown in fig. 2, and the apparatus may be applied to various electronic devices.
As shown in fig. 6, the apparatus 600 for querying data according to the present embodiment includes: a receiving unit 601, a determining unit 602, and a data returning unit 603. The receiving unit 501 is configured to receive a data query request sent by a user terminal, where the data query request includes a user identifier, a field name, and a data version number; the determining unit 602 is configured to determine whether there is target level data in a level data set, where the target level data includes a data identifier that matches the user identifier and a data version number that is the same as the data version number included in the data query request, and the level data set is stored in a memory in advance, and each level data in the level data set is provided with a data identifier and a data version number; and the data returning unit 603 is configured to, in response to determining that the target hierarchical data exists in the hierarchical data set, determine, based on the target hierarchical data, data related to a field indicated by the field name requested by the data query request, and return the data to the user terminal.
In the present embodiment, in the apparatus 600 for querying data: the specific processing of the receiving unit 601, the determining unit 602, and the data returning unit 603 and the technical effects thereof can refer to the related descriptions of step 201, step 202, and step 203 in the corresponding embodiment of fig. 2, which are not described herein again.
In some optional implementations of this embodiment, for each hierarchical data in the hierarchical data set, each hierarchy of the hierarchical data may include at least one data node provided with a node identifier; for each level in the hierarchical data that is not the last level, the data node may include, for each data node in the level, at least one data node in a level next to the level; each data node in the last hierarchy is a leaf node, and for each data node included in a hierarchy above the last hierarchy, the data node stores the leaf node number of the included leaf node.
In some optional implementation manners of this embodiment, the data query request may further include a request type and a query condition, where the request type is any one of the following: recording inquiry and quantity inquiry; and the data returning unit 603 may include: a searching subunit (not shown in the figure), configured to search, if the request type is record query, data under the field that satisfies the query condition in the target level data.
In some optional implementation manners of this embodiment, when the request type is a record query, the data query request may further include a data return starting value and a data number; and the searching subunit may further include: a search module (not shown in the figure), configured to determine, if the field name is used to represent data included in a leaf node, a target data node that meets the query condition in a level immediately preceding a last level of the target level data, and generate a target data node sequence; determining a first target data node to which a target leaf node indicated by the data return starting value belongs in the target data node sequence based on the leaf node number stored in the target data node sequence; and traversing leaf nodes included in the first target data node and/or leaf nodes included in data nodes in the sequence of the target data nodes, which are sequentially inferior to the first target data node, from the target leaf node in sequence until the data under the fields with the number of data are found, and returning the found data to the user terminal.
In some optional implementation manners of this embodiment, the data returning unit 603 may further include: a first data returning subunit (not shown in the figure), configured to determine, if the request type is a quantity query and the field name is used to characterize the quantity of leaf nodes, data nodes that satisfy the query condition among data nodes included in a level immediately above a last level of the target level data, so as to generate a data node set; and if the data node set comprises one data node, returning the leaf node number stored by the data node to the user terminal.
In some optional implementation manners of this embodiment, the data returning unit 603 may further include: a second data returning subunit (not shown in the figure), configured to, if the data node set includes at least two data nodes, sum the leaf node numbers respectively stored in the data nodes in the data node set, and return the summed value to the user terminal.
In some optional implementations of this embodiment, for each hierarchical data in the hierarchical data set, the node identifiers of the leaf nodes belonging to the hierarchical data may be stored by a bitmap method.
In some optional implementations of this embodiment, the apparatus 600 may further include: a first data returning unit (not shown in the figure), configured to, in response to determining that the target hierarchical data does not exist in the hierarchical data set, forward the data query request to a connected data storage server, so as to receive the data requested by the data query request from the data storage server, and return the received data to the user terminal.
In some optional implementations of this embodiment, the apparatus 600 may further include: and a second data returning unit (not shown in the figure) configured to return a data invalidation notification message to the user terminal in response to determining that the target hierarchical data does not exist in the hierarchical data set.
The device provided by the embodiment of the application avoids that the data returned to the user terminal is invalid data through determining the target level data, thereby improving the validity of data query.
Referring now to FIG. 7, shown is a block diagram of a computer system 700 suitable for use in implementing a server according to embodiments of the present application. The server shown in fig. 7 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present application.
As shown in fig. 7, the computer system 700 includes a Central Processing Unit (CPU)701, which can perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM)702 or a program loaded from a storage section 708 into a Random Access Memory (RAM) 703. In the RAM 703, various programs and data necessary for the operation of the system 700 are also stored. The CPU 701, the ROM 702, and the RAM 703 are connected to each other via a bus 704. An input/output (I/O) interface 705 is also connected to bus 704.
The following components are connected to the I/O interface 705: an input portion 706 including a keyboard, a mouse, and the like; an output section 707 including a display such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage section 708 including a hard disk and the like; and a communication section 709 including a network interface card such as a LAN card, a modem, or the like. The communication section 709 performs communication processing via a network such as the internet. A drive 710 is also connected to the I/O interface 705 as needed. A removable medium 711 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 710 as necessary, so that a computer program read out therefrom is mounted into the storage section 708 as necessary.
In particular, according to an embodiment of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program can be downloaded and installed from a network through the communication section 709, and/or installed from the removable medium 711. The computer program executes the above-described functions defined in the system of the present application when executed by the Central Processing Unit (CPU) 701.
It should be noted that the computer readable medium shown in the present application may be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present application, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In this application, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in the embodiments of the present application may be implemented by software or hardware. The described units may also be provided in a processor, and may be described as: a processor includes a receiving unit, a determining unit, and a data returning unit. The names of these units do not in some cases form a limitation on the units themselves, and for example, a receiving unit may also be described as a "unit that receives a data query request sent by a user terminal".
As another aspect, the present application also provides a computer-readable medium, which may be contained in the server described in the above embodiments; or may exist separately and not be assembled into the server. The computer readable medium carries one or more programs which, when executed by a server, cause the server to comprise: receiving a data query request sent by a user terminal, wherein the data query request comprises a user identifier, a field name and a data version number; determining whether target level data which comprises a data identifier matched with the user identifier and comprises a data version number identical to the data version number contained in the data query request exists in a level data set, wherein the level data set is stored in a memory in advance, and each level data in the level data set is provided with the data identifier and the data version number; and in response to determining that the target hierarchy data exists in the hierarchy data set, determining data related to the field indicated by the field name requested by the data query request based on the target hierarchy data, and returning the data to the user terminal.
The above description is only a preferred embodiment of the application and is illustrative of the principles of the technology employed. It will be appreciated by those skilled in the art that the scope of the invention herein disclosed is not limited to the particular combination of features described above, but also encompasses other arrangements formed by any combination of the above features or their equivalents without departing from the spirit of the invention. For example, the above features may be replaced with (but not limited to) features having similar functions disclosed in the present application.

Claims (17)

1. A method for querying data, the method comprising:
receiving a data query request sent by a user terminal, wherein the data query request comprises a user identifier, a field name and a data version number, the data query request further comprises a request type and a query condition, the request type comprises record query, and when the request type is record query, the data query request further comprises a data return initial value and a data number;
determining whether target level data which contains a data identifier matched with the user identifier and contains a data version number identical to the data version number contained in the data query request exists in a level data set, wherein the level data set is stored in a memory in advance, and each level data in the level data set is provided with the data identifier and the data version number;
in response to determining that the target hierarchical data exists in the hierarchical data set, determining data requested by the data query request and related to the field indicated by the field name based on the target hierarchical data, and returning the data to the user terminal;
wherein determining, based on the target hierarchy data, data requested by the data query request that is related to the field indicated by the field name comprises:
if the field name is used for representing data contained in leaf nodes, determining target data nodes meeting the query condition in the last level of the target level data, and generating a target data node sequence; determining a first target data node to which a target leaf node indicated by the data return starting value belongs in the target data node sequence based on the number of leaf nodes stored by the target data node in the target data node sequence; starting from the target leaf node until the data under the field with the number of the data is found, and returning the found data to the user terminal.
2. The method according to claim 1, wherein for each hierarchical data in the set of hierarchical data, each hierarchy of the hierarchical data comprises at least one data node provided with a node identification; for each level in the level data that is not the last level, for each data node in the level, the data node comprises at least one data node in a level next to the level; each data node in the last hierarchy is a leaf node, and for each data node included in a hierarchy above the last hierarchy, the data node stores the leaf node number of the included leaf node.
3. The method according to one of claims 1-2, wherein the request type further comprises a quantity query.
4. The method of claim 1, wherein starting from the target leaf node until the number of data under the field is found, comprises:
and sequentially traversing leaf nodes included by the first target data node and/or leaf nodes included by data nodes sequentially inferior to the first target data node in the target data node sequence from the target leaf node until the data under the fields with the number of data is found.
5. The method of claim 3, wherein determining the data related to the field indicated by the field name requested by the data query request based on the target tier data further comprises:
if the request type is a quantity query and the field name is used for representing the quantity of leaf nodes, determining data nodes meeting the query condition in data nodes included in a level immediately above the last level of the target level data to generate a data node set; and if the data node set comprises one data node, returning the leaf node number stored by the data node to the user terminal.
6. The method of claim 5, wherein determining, based on the target-level data, data requested by the data query request that is related to the field indicated by the field name further comprises:
and if the data node set comprises at least two data nodes, summing the leaf node numbers respectively stored by each data node in the data node set, and returning the numerical value obtained by summation to the user terminal.
7. The method of claim 2, wherein for each level data in the set of level data, node identities of leaf nodes attributed to that level data are stored by a bitmap method.
8. The method of claim 1, further comprising:
and in response to determining that the target hierarchical data does not exist in the hierarchical data set, forwarding the data query request to the connected server for data storage, so as to receive the data requested by the data query request from the server for data storage, and returning the received data to the user terminal.
9. The method of claim 1, further comprising:
and in response to determining that the target hierarchical data does not exist in the hierarchical data set, returning data invalidation prompting information to the user terminal.
10. An apparatus for querying data, the apparatus comprising:
the data query device comprises a receiving unit, a sending unit and a processing unit, wherein the receiving unit is configured to receive a data query request sent by a user terminal, the data query request comprises a user identifier, a field name and a data version number, the data query request further comprises a request type and a query condition, the request type comprises a record query, and when the request type is the record query, the data query request further comprises a data return initial value and a data number;
a determining unit, configured to determine whether there is target level data in a level data set, where the target level data includes a data identifier that matches the user identifier and includes a data version number that is the same as the data version number included in the data query request, and the level data set is stored in a memory in advance, and each level data in the level data set is provided with a data identifier and a data version number;
a data returning unit configured to, in response to determining that the target hierarchical data exists in the hierarchical data set, determine, based on the target hierarchical data, data related to a field indicated by the field name requested by the data query request, and return the data to the user terminal;
wherein, look for the subunit and include: a search module configured toIf the field name is used for representing data contained in leaf nodes, determining target data nodes meeting the query condition in the last level of the target level data, and generating a target data node sequence; determining a first target data node to which a target leaf node indicated by the data return starting value belongs in the target data node sequence based on the number of leaf nodes stored by the target data node in the target data node sequence; starting from the target leaf node until the data under the field with the number of the data is found, and returning the found data to the user terminal.
11. The apparatus according to claim 10, wherein for each hierarchical data in the set of hierarchical data, each hierarchy of the hierarchical data comprises at least one data node provided with a node identification; for each level in the level data that is not the last level, for each data node in the level, the data node comprises at least one data node in a level next to the level; each data node in the last hierarchy is a leaf node, and for each data node included in a hierarchy above the last hierarchy, the data node stores the leaf node number of the included leaf node.
12. The apparatus according to one of claims 10-11, wherein the request type further comprises a quantity query.
13. The apparatus of claim 10, wherein the searching module is further configured to sequentially traverse leaf nodes included in the first target data node and/or leaf nodes included in data nodes next to the first target data node in the sequence of target data nodes, starting from the target leaf node, until the data under the data number of the fields is found.
14. The apparatus of claim 12, wherein the data return unit further comprises:
a first data returning subunit, configured to determine, if the request type is a quantity query and the field name is used to characterize the quantity of leaf nodes, data nodes that satisfy the query condition among data nodes included in a level immediately above a last level of the target level data, so as to generate a data node set; and if the data node set comprises one data node, returning the leaf node number stored by the data node to the user terminal.
15. The apparatus of claim 14, wherein the data return unit further comprises:
and the second data returning subunit is configured to sum the leaf node numbers respectively stored by the data nodes in the data node set if the data node set includes at least two data nodes, and return the summed value to the user terminal.
16. A server, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-9.
17. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the method according to any one of claims 1-9.
CN201710242321.6A 2017-04-13 2017-04-13 Method and device for querying data Active CN108733668B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710242321.6A CN108733668B (en) 2017-04-13 2017-04-13 Method and device for querying data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710242321.6A CN108733668B (en) 2017-04-13 2017-04-13 Method and device for querying data

Publications (2)

Publication Number Publication Date
CN108733668A CN108733668A (en) 2018-11-02
CN108733668B true CN108733668B (en) 2021-10-19

Family

ID=63923760

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710242321.6A Active CN108733668B (en) 2017-04-13 2017-04-13 Method and device for querying data

Country Status (1)

Country Link
CN (1) CN108733668B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110795632B (en) * 2019-10-30 2022-10-04 北京达佳互联信息技术有限公司 State query method and device and electronic equipment
CN113779081A (en) * 2021-01-04 2021-12-10 北京沃东天骏信息技术有限公司 Cascade information redisplay method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102546798A (en) * 2011-12-31 2012-07-04 易程科技股份有限公司 Data transmission method and system of train-mounted terminal, server and train-mounted terminal
CN103106092A (en) * 2013-02-18 2013-05-15 青岛海信宽带多媒体技术有限公司 System software updating method and device in terminal appliance
CN103793470A (en) * 2013-12-31 2014-05-14 远光软件股份有限公司 Data processing method and data processing device

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
AU2003903306A0 (en) * 2003-06-27 2003-07-10 Common Ground Publishing Pty Ltd Method and apparatus for extending the range of useability of ontology driven systems and for creating interoperability between different mark-up schemas for the creation, location and formatting of digital content
EP2990970A1 (en) * 2014-08-26 2016-03-02 Dassault Systèmes Execution of sequential update
US10262012B2 (en) * 2015-08-26 2019-04-16 Oracle International Corporation Techniques related to binary encoding of hierarchical data objects to support efficient path navigation of the hierarchical data objects
CN105488172B (en) * 2015-11-30 2019-09-17 北京奇艺世纪科技有限公司 A kind of location-based data query method and device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102546798A (en) * 2011-12-31 2012-07-04 易程科技股份有限公司 Data transmission method and system of train-mounted terminal, server and train-mounted terminal
CN103106092A (en) * 2013-02-18 2013-05-15 青岛海信宽带多媒体技术有限公司 System software updating method and device in terminal appliance
CN103793470A (en) * 2013-12-31 2014-05-14 远光软件股份有限公司 Data processing method and data processing device

Also Published As

Publication number Publication date
CN108733668A (en) 2018-11-02

Similar Documents

Publication Publication Date Title
CN110019211A (en) The methods, devices and systems of association index
CN108846753B (en) Method and apparatus for processing data
CN109388626B (en) Method and apparatus for assigning numbers to services
CN105472045A (en) Database migration method and database migration device
CN111061680A (en) Data retrieval method and device
CN107247798B (en) Method and device for constructing search word bank
CN112818654B (en) Message storage method, message generation method, device, electronic equipment and computer readable medium
CN110909022A (en) Data query method and device
CN110554951B (en) Buried point management method and device
CN108733668B (en) Method and device for querying data
CN113761565B (en) Data desensitization method and device
CN111401684A (en) Task processing method and device
CN105843809B (en) Data processing method and device
CN112182138A (en) Catalog making method and device
CN110851343A (en) Test method and device based on decision tree
CN117009430A (en) Data management method, device, storage medium and electronic equipment
CN111309932B (en) Comment data query method, comment data query device, comment data query equipment and storage medium
CN113138943B (en) Method and device for processing request
JP2014524210A (en) Generate variable length nonce
CN113704242A (en) Data processing method and device
CN108322380B (en) Method and device for calling data and method and device for pushing information
CN111737218A (en) File sharing method and device
CN110019671B (en) Method and system for processing real-time message
CN113760343A (en) Method and device for processing service request
CN107025300B (en) Data query method and device

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
GR01 Patent grant
GR01 Patent grant