Method, device and storage medium for querying medical data
By generating a second query instruction using a preset mapping relationship after receiving the first query instruction, the target medical data can be directly retrieved from the horizontal table of the target database, solving the problem of difficult vertical table queries and realizing convenient and real-time data query.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHANGHAI TAIMEI DIGITAL TECH CO LTD
- Filing Date
- 2023-02-27
- Publication Date
- 2026-04-21
AI Technical Summary
In existing technologies, medical data is large in quantity but has few individual fields, making it difficult to query when stored in vertical tables. Furthermore, existing query methods cannot achieve real-time performance and convenience.
By receiving the first query instruction, a second query instruction is generated using a preset mapping relationship, which instructs the target field and record in the horizontal table of the target database to directly obtain the target medical data.
It improves the convenience and real-time nature of medical data retrieval, reduces the learning burden on data analysis system staff, and avoids the need to maintain multiple data tables.
Smart Images

Figure CN116244334B_ABST
Abstract
Description
Technical Field
[0001] The embodiments described in this specification pertain to the field of data processing, and specifically relate to a method, apparatus, device, and storage medium for querying medical data. Background Technology
[0002] Currently, medical data is characterized by a large volume but a relatively small number of individual data points corresponding to each field. Therefore, medical data is often stored in vertical tables, making data retrieval difficult. To address this, existing technologies periodically extract medical data from the vertical tables and construct horizontal medical data tables. This allows data analysis systems to extract data from these tables using general query commands, rather than directly from the medical database. However, the real-time performance of medical data in these tables is not high. To improve the real-time retrieval of medical data, the storage structure can be modified, and the target medical data can be maintained and queried based on this modified structure. This, in turn, prevents real-time queries using the medical data query commands provided by the data analysis system. Therefore, existing technologies suffer from the technical problem of cumbersome medical data retrieval. Summary of the Invention
[0003] In view of this, several embodiments of this specification aim to provide a method for querying medical data, thereby improving the convenience of querying target medical data to a certain extent.
[0004] This specification provides a method for querying medical data using multiple embodiments. The method is applied to a data platform and includes: receiving a first query instruction; wherein the first query instruction includes a first instruction parameter for indicating target medical data; generating a second query instruction based on a mapping result obtained according to a preset mapping relationship between the first and second instruction parameters; wherein the second query instruction indicates a target field and a target record of the medical data in a horizontal table of a target database; sending the second query instruction to the target database to obtain the target medical data located in the target field and the target record; and feeding back the target medical data to the sender of the first query instruction.
[0005] This specification provides a method for querying medical data using multiple embodiments. The method is applied to a database management system and includes: receiving a second query instruction for target medical data; wherein the second query instruction indicates a target field and a target record of the target medical data in a horizontal table of a target database; based on the second query instruction, extracting the target medical data that is located in the target field and the target record from the target database; and feeding back the target medical data to the sender of the second query instruction.
[0006] One embodiment of this specification provides a medical data query device, the device comprising: a receiving module for receiving a first query instruction; wherein the first query instruction includes a first instruction parameter for indicating target medical data; a generating module for generating a second query instruction based on a mapping result obtained according to a preset mapping relationship between the first instruction parameter and the second instruction parameter; wherein the second query instruction indicates a target field and a target record of the medical data in a horizontal table of a target database; a sending module for sending the second query instruction to the database to obtain the target medical data located in the target field and the target record; and a feedback module for feeding back the target medical data to the sender of the first query instruction.
[0007] One embodiment of this specification provides a medical data query device, the device comprising: a receiving module for receiving a second query instruction for target medical data; wherein the second query instruction indicates a target field and a target record of the target medical data in a horizontal table of a target database; an extraction module for extracting the target medical data located in the target field and the target record from the target database based on the second query instruction; and a feedback module for feeding back the target medical data to the sender of the second query instruction.
[0008] The various implementations provided in this specification, upon receiving a first query instruction, determine the second instruction parameter corresponding to the first instruction parameter according to a preset mapping relationship between the first instruction parameter and the second instruction parameter, thereby generating a second query instruction. The second query instruction is then sent to the target database to retrieve the target medical data located in the target field and the target record, thus improving the convenience of querying target medical data. Attached Figure Description
[0009] Figure 1 This is a schematic diagram of the architecture of a medical query system provided for one embodiment of this specification.
[0010] Figure 2 This is a flowchart illustrating a medical query method provided as one embodiment of this specification.
[0011] Figure 3 This is a schematic diagram of a medical query method provided as one embodiment of this specification.
[0012] Figure 4 This is a flowchart illustrating a medical query method provided as one embodiment of this specification.
[0013] Figure 5A schematic diagram of a medical query device provided for one embodiment of this specification.
[0014] Figure 6 A schematic diagram of a medical query device provided for one embodiment of this specification.
[0015] Figure 7 A schematic diagram of a computer device provided for one embodiment of this specification. Detailed Implementation
[0016] Overview
[0017] In related technologies, medical data is often voluminous, but the number of data points within the same field can be small. This results in strong sparsity in medical data. Storing medical data in horizontal tables of a relational database could lead to a large number of tables requiring maintenance. Therefore, related technologies often store medical data in vertical tables. For example, medical data can be stored in a database with an EAV data structure. However, storing medical data in vertical tables can make querying the target medical data difficult. Therefore, in some implementations, the medical data stored in the vertical tables can be synchronized to a designated database and stored in a data structure that is more conducive to querying.
[0018] In related technologies, staff working on medical data analysis systems may provide relatively generic query commands, which can prevent the direct retrieval of target medical data from a specific database. To retrieve the target medical data directly from a specific database, staff need to input query commands tailored to the database's data structure.
[0019] Therefore, it is necessary to provide a method for querying medical data. Upon receiving a first query instruction, a second query instruction is generated by determining the corresponding second instruction parameter based on a preset mapping relationship between the first and second instruction parameters. This second query instruction is then sent to a target database to retrieve the target medical data located in the target field and the target record. This method improves the convenience of querying target medical data.
[0020] System Architecture
[0021] Please see Figure 1 This specification provides a medical data query system. The medical data query system may include a client and at least one server. The client may provide a first query command. The server may include a server with a data middleware platform deployed and a server with a database management system deployed.
[0022] The client can be an electronic device with network access capabilities. Specifically, for example, the client can be a desktop computer, tablet computer, laptop computer, smartphone, digital assistant, smart wearable device, shopping guide terminal, television, smart speaker, microphone, etc. Among them, smart wearable devices include, but are not limited to, smart bracelets, smartwatches, smart glasses, smart helmets, smart necklaces, etc. Alternatively, the client can also be software that can run on the electronic device. The server can be an electronic device with a certain computing power. It can have a network communication module, processor, and memory, etc. Of course, the server can also refer to the software running on the electronic device. The server can also be a distributed server, which can be a system with multiple processors, memory, network communication modules, etc. working together. Alternatively, the server can also be a server cluster formed by several servers. Alternatively, with the development of science and technology, the server can also be a new technical means that can realize the corresponding functions of the embodiments described in the specification. For example, it can be a new form of "server" based on quantum computing.
[0023] Example method
[0024] Please see Figure 2 This specification provides a method for querying medical data in one embodiment. The method can be applied to a server. The server may be equipped with a data platform. The method may include the following steps.
[0025] Step S110: Receive a first query instruction; wherein the first query instruction includes a first instruction parameter for indicating target medical data.
[0026] In some cases, medical data can be stored in vertical tables. To facilitate querying medical data within these vertical tables, data can be periodically extracted and used to construct a horizontal medical data table. The medical data analysis system can then extract the target medical data from this table according to a first query instruction. To improve the ease of medical data retrieval and reduce the learning burden on data analysis system personnel, the system can receive the first query instruction and generate a second query instruction based on a second query instruction to retrieve the target medical data from a target database that provides relatively real-time medical data.
[0027] The first query instruction can represent a general query instruction for target medical data. The medical query instruction may include a first instruction parameter and a keyword. The first instruction parameter can be used to indicate the target medical data. Specifically, for example, the first query instruction can be an SQL statement. The keyword can be a keyword in the SQL statement, such as SELECT, FROM, and WHERE. The first instruction parameter can be a parameter of the SQL statement. The first instruction parameter can correspond to a keyword. For example, the first instruction parameter can be a field identifier. Combined with the SELECT keyword, the data value of the field indicated by the first instruction parameter can be extracted from the database. Alternatively, the first instruction parameter can also be a range of data values in the database. Combined with the WHERE keyword, the data in the database can be filtered. Of course, the first query instruction can also be an Oracle statement, etc.
[0028] The first query instruction may be provided by a medical data analysis system. The method of receiving the first query instruction may be to receive a pre-configured first query instruction provided by the data analysis system. Alternatively, the first query instruction may be a first query instruction entered by a staff member on a client. Correspondingly, the method of receiving the first query instruction may be to receive a first query instruction sent by a client.
[0029] Step S120: Generate a second query instruction based on the mapping result obtained from the first instruction parameter according to the preset mapping relationship between the first instruction parameter and the second instruction parameter; wherein, the second query instruction is used to indicate the target field and target record of the medical data in the horizontal table of the target database. At least one field in the horizontal table of the target data includes medical data representing different categories.
[0030] In some cases, a corresponding second query instruction can be generated based on the first query instruction. Following the second query instruction, the target medical data can be extracted from the target database and further fed back to the sender of the first query instruction. This can improve the convenience of querying target medical data to a certain extent. Furthermore, different types of medical data can be stored in the same field within a horizontal table of the target database. Therefore, the second query instruction, used to indicate the target field and target record of the medical data in the horizontal table of the target database, indicates that different types of medical data can be stored in the same data table within the target database. This avoids, to some extent, the problem of sparse medical data requiring the maintenance of numerous data tables, but with each data table storing a small amount of medical data.
[0031] The second query instruction can represent a query instruction targeting a target database storing medical data. The second query instruction can at least indicate the target fields and target records of the target medical data in a horizontal table of the target database. Specifically, the second query instruction, like the first query instruction, can be constructed using SQL statements. The SQL statement represented by the second query instruction can be used to query the target medical data targeted by the first query instruction in the target database. Specifically, for example, the first query instruction can target a horizontal table storing medical data. The first query instruction can be "select a,b from form_1". Correspondingly, the target database targeted by the second query instruction can have only one horizontal table, form_0. This horizontal table can include an identifier field storing form identifiers. The form identifier can be used to indicate the medical form corresponding to the data of each record in the data table of the target database. Correspondingly, the second query instruction can be "select a,b from form_0 where form_id == 1".
[0032] In some implementations, the second query instruction can also be an ORACLE statement, which allows querying target medical data in the target database.
[0033] The preset mapping relationship between the first instruction parameter and the second instruction parameter can be a pre-defined method to indicate the location of the target medical data indicated by the first query instruction in the target database. The first query instruction can target a data structure for one type of medical data storage. The second query instruction can target a data structure for another type of medical data storage. Accordingly, there can be a preset correspondence between the data structure corresponding to the first query instruction and the data structure corresponding to the second query instruction.
[0034] Specifically, for example, please see Figure 3The first query instruction can target multiple medical forms. The second query instruction can target a single columnar data table. The data table in the target database can include a first identifier field storing entity identifiers, a second identifier field storing form identifiers, and at least one data field storing medical data. Different form identifiers can correspond to at least one logical field associated with a data field. The logical field can be used to indicate the medical attributes represented by the medical data stored in its associated data field. Accordingly, among the multiple medical forms targeted by the first query instruction, the form identifiers of the medical forms correspond to the second identifier field in the data table of the target database, and the fields of the medical forms correspond to columns 1 to 4 in the data table of the target database, including the corresponding form identifier records. Accordingly, based on the correspondence of medical data under different data structures, a preset mapping relationship between the first instruction parameter and the second instruction parameter can be constructed. Specifically, for example, if the first instruction parameter includes a first field identifier representing height, according to the preset mapping relationship between the first instruction parameter and the second instruction parameter, the second field identifier column 2 corresponding to the first field identifier representing height can be obtained. The second field identifier can be used as the second instruction parameter.
[0035] The method for generating a second query instruction based on the mapping result obtained from the mapping result of the first instruction parameters according to the preset mapping relationship between the first instruction parameters and the second instruction parameters can be based on a preset template of correspondence between query instruction keywords. The second instruction parameter corresponding to the first instruction parameter is filled into the template to obtain the second query instruction. Alternatively, the method can also convert the keywords of the first query instruction into keywords of the second query instruction according to preset rules, and combine the second instruction parameters with the keywords of the second query instruction according to the preset mapping relationship between the first and second instruction parameters to generate a target query instruction. Specifically, for example, both the first and second query instructions can be constructed using SQL statements. If the first query instruction includes the keyword "FROM" indicating the target medical form, the second query instruction can construct the keyword "WHRER" for conditional querying to further query the target field in records in the second identifier field that match the form identifier of the target medical table.
[0036] Step S130: Send the second query instruction to the target database to obtain the target medical data that is in the target field and in the target record.
[0037] In some cases, after generating a second query instruction, it can be sent to the target database to retrieve the target medical data. The second query instruction can conveniently provide the user with the target medical data.
[0038] The target database can be a database that stores medical data based on a columnar storage structure. Specifically, for example, the target database may include a first identifier field storing entity identifiers, a second identifier field storing form identifiers, and at least one data field storing medical data. The entity identifier and form identifier can be used to indicate the medical entity and medical form corresponding to the medical data in each row of a data table in the target database, respectively. Different form identifiers can correspond to at least one logical field associated with a data field. The logical field can be used to indicate the medical attributes represented by the medical data stored in its associated data field.
[0039] Specifically, for example, please see Figure 3 In the target database's data table, columns 1, 2, 3, and 4 can be data fields. The first identifier field can store entity identifiers, which can be represented by entity names. The second identifier field can store form identifiers T1 and T2, used to indicate medical form T1 and medical form T2, respectively. Column 1 of the data field can store medical data, including the names and codes of medical entities. Therefore, the logical fields corresponding to form identifier T1 can include fields indicating the medical data corresponding to the data in column 1. Similarly, the logical fields corresponding to form identifier T2 can include fields indicating the medical data corresponding to the data in column 2.
[0040] Accordingly, upon receiving the second query instruction, the target database can select the target record and target field containing the target data based on the second query instruction. Specifically, for example, the second query instruction may require finding the medication name of the medical entity in medical form T1. Accordingly, the second query instruction can retrieve the target record including the form identifier T1 from the data table of the target database. Combining this with the logical field corresponding to the form identifier T1, the target medical data identifying the medication name stored in column 3 can be retrieved.
[0041] The target field can refer to the target column of the target medical data in the data table of the target database. The target record can be used to refer to the target row of the target medical data in the data table of the target database.
[0042] The second query command can be sent to the target database directly from the server with the data middleware deployed to the server with the database management system deployed. Alternatively, it can be sent to the target database's data management system via an intermediate server.
[0043] Step S140: Feed back the target medical data to the sender of the first query command.
[0044] In some cases, after the database management system of the target database feeds back the target medical data to the data platform, the data platform can return the first query instruction to the sender.
[0045] The sender can refer to the client providing the first query instruction. For example, the sender could be a client belonging to a medical professional. Alternatively, the sender could be a server deployed with a data analysis system. The data analysis system can periodically extract target medical data for analysis.
[0046] In some implementations, the first instruction parameter includes a first field identifier for indicating a field of the target medical data in the medical form; the step of generating a second query instruction based on the mapping result obtained according to the first instruction parameter and a preset mapping relationship between the first instruction parameter and the second instruction parameter includes: determining a second field identifier corresponding to the first field identifier according to the preset mapping relationship between the first instruction parameter and the second instruction parameter; wherein the second field identifier serves as the second instruction parameter; the second field identifier is used to indicate the target field; and the second query instruction is generated based on the second field identifier.
[0047] In some cases, the first instruction parameter of the first query instruction may include a first field identifier. The first field identifier can be used to determine a second field identifier relative to the target database. Furthermore, the target medical data corresponding to the second field identifier can be extracted from the target database.
[0048] The first field identifier can represent a field in the data structure targeted by the first query instruction, indicating the target medical data to be queried. Correspondingly, the second field identifier can represent the position of the target medical data in the target database table. The second field identifier can be used to determine the target field. Based on a preset mapping relationship between the first and second instruction parameters, the second field identifier can be determined using the first field identifier. Furthermore, a second query instruction can be generated based on the second field identifier and a pre-set query instruction template.
[0049] In some implementations, the first instruction parameter further includes a target form identifier indicating the target medical form to which the target medical data belongs; multiple preset mapping relationships are set for different medical forms; the step of determining the second field identifier corresponding to the first field identifier based on the preset mapping relationship between the first instruction parameter and the second instruction parameter includes: matching a target preset mapping relationship among the multiple preset mapping relationships based on the target form identifier; and determining the field identifier of the target field in the horizontal table of the target database relative to the first field identifier as the second field identifier according to the target mapping relationship.
[0050] In some cases, the target database's data tables may include medical data from different medical forms. Specifically, at least two records in the target database's data tables may correspond to different form identifiers. The records corresponding to different form identifiers may store different types of medical data. For example, please refer to... Figure 3 The types of medical data differ in different records, including form identifier T1 and form identifier T2. Specifically, in the record including form identifier T1, the medical data corresponding to column 1 can represent the name of a medical entity, while in the record including form identifier T2, the medical data corresponding to column 1 can represent the code of a medical entity. Therefore, there can be multiple preset mapping relationships between the first instruction parameter and the second instruction parameter for different form identifiers, used to indicate the types of medical data stored in different data fields in the records of the corresponding form identifiers. Correspondingly, the step of determining the second field identifier corresponding to the first field identifier based on the preset mapping relationship between the first instruction parameter and the second instruction parameter can include matching a target preset mapping relationship among the multiple preset mapping relationships based on the target form identifier. The target mapping relationship can also represent multiple logical fields associated with data fields corresponding to the form identifier. Further, according to the target mapping relationship, the field identifier of the target field in the horizontal table of the target database relative to the first field identifier can be determined as the second field identifier.
[0051] In some implementations, the first instruction parameter further includes a target entity identifier for indicating the medical entity corresponding to the target medical data; the horizontal table of the database includes a first identifier field storing the entity identifier and a data field storing the medical data; the entity identifier is used to indicate the medical entity corresponding to the medical data belonging to the same record in the horizontal table as the entity identifier; correspondingly, the target entity identifier is also used to indicate the target record of the target medical data in the horizontal table of the target database.
[0052] In some cases, the analysis of medical data can be targeted at different medical entities. Therefore, the first instruction parameter may also include a target entity identifier to indicate the medical entity corresponding to the target medical data. Accordingly, the database may be a column-oriented database. The horizontal table of the database may include a first identifier field storing the entity identifier and a data field storing the medical data. Accordingly, the target entity identifier may also be used to indicate the target record of the target medical data in the horizontal table of the target database.
[0053] In some implementations, the first instruction parameter further includes a target form identifier indicating the target medical form to which the target medical data belongs, and a target entity identifier indicating the medical entity corresponding to the target medical data; the second instruction parameter includes at least query condition parameters and query field parameters; the step of generating the second query instruction based on the second form identifier and the second field identifier includes: setting the second field identifier as the query field parameter of the second query instruction; the query field parameter is used to determine the target field in the horizontal table of the target database; determining the target form identifier and the target entity identifier as the query condition parameters of the second query instruction; the query condition parameters are used to determine the target record in the horizontal table of the target database; and generating the second query instruction based on the query field parameters and the corresponding query keywords, as well as the query condition parameters and the corresponding condition keywords.
[0054] In some implementations, the first query instruction is used to query target medical data in a relational database; the second query instruction is used to query data in a columnar storage database; wherein the columnar storage database includes a first identifier field storing entity identifiers, a second identifier field storing form identifiers, and at least one data field storing medical data. Different form identifier fields correspond to logical fields associated with data fields. The logical fields are used to indicate the medical attributes corresponding to the medical data in the data fields of records including the corresponding form identifiers.
[0055] In some cases, columnar storage databases can store medical data corresponding to multiple medical forms in the same table, which can, to some extent, avoid the problem of needing to maintain multiple tables in the database due to the high sparsity of medical data.
[0056] In some embodiments, the medical data query method may further include: constructing a medical data table by combining a first field identifier and target medical data retrieved from a target database according to a second field identifier. The medical data table includes medical data corresponding to the first field identifier.
[0057] In some cases, after obtaining the target medical data from the target database, the data platform can combine the target medical data with the first field identifier to form a medical data table for processing. For example, the first query instruction can be issued by the data analysis system. Correspondingly, the data platform can retrieve the target medical data from the target database according to the second query instruction and construct query results that match the first query instruction.
[0058] Please see Figure 4 This specification provides a method for querying medical data in one embodiment. The method can be applied to a server. The server may be equipped with a database management system. The method may include the following steps.
[0059] Step S210: Receive a second query instruction for the target medical data; wherein the second query instruction is used to indicate the target field and target record of the target medical data in the horizontal table of the target database.
[0060] In some cases, the data management system of the target database can, upon receiving the second query instruction, retrieve the target medical data stored in the target fields and target records from the horizontal table of the target database according to the second query instruction.
[0061] The method for receiving the second query instruction for the target medical data can be that the data platform sends the instruction, and the database management system receives it. Alternatively, the data platform can send the instruction to an intermediate server, which then forwards it to the database management system for receipt.
[0062] Step S220: Based on the second query instruction, extract the target medical data that is in the target field and in the target record from the target database.
[0063] In some cases, based on the second query instruction, target medical data can be extracted from the target database. The second query instruction may include a field indicating the target fields and records of the target medical data within the target database's tables. Specifically, for example, the target database tables may include a first identifier field that records entity identifiers. In the data structure targeted by the first query instruction, different entity identifiers may be stored in different tables. In the data structure targeted by the second query instruction, different entity identifiers may be stored in different records within the same table. This can, to some extent, avoid the problem of maintaining numerous data tables due to excessively sparse medical data. Therefore, based on the entity identifier and the first field identifier, the target fields and records of the target medical data within the target database's tables can be determined, and these target fields and records can be further extracted.
[0064] Step S230: Feed back the target medical data to the sender of the second query command.
[0065] In some cases, after retrieving the target medical data from the target database, the target medical data can be returned to the sender of the second query instruction. The sender of the second query instruction can be a data platform or an intermediate server during the data transmission process.
[0066] In some implementations, the second query instruction includes a target form identifier to which the target medical data belongs, a target entity identifier indicating the medical entity corresponding to the target medical data, and a second field identifier indicating the target medical data in a horizontal table of the target database. The step of extracting the target medical data that is located in the target field and in the target record from the target database based on the second query instruction includes: matching the target record corresponding to the target form identifier and the target entity identifier in the horizontal table of the database according to the second query instruction; extracting the target medical data corresponding to the second field identifier from the target record; merging the target medical data corresponding to the same medical target entity identifier to obtain a medical data sub-table corresponding to the medical entity identifier; constructing a medical data table including the target medical data based on the medical data sub-table; correspondingly, in the step of feeding back the target medical data to the sender of the second query instruction, the medical data table is fed back to the sender of the second query instruction.
[0067] In some cases, the second query instruction may include a target form identifier, a target entity identifier, and a second field identifier. The target form identifier and target entity identifier can be used to identify the records of the target medical data within the horizontal table of the target database. The second field identifier can be used to identify the fields of the target medical data within the horizontal table of the target database.
[0068] In some implementations, the target record can be extracted first based on the target form identifier, and the target field represented by the second field identifier can be extracted from the target record. Next, the target medical data corresponding to the same medical target entity identifier are merged to obtain a medical data sub-table corresponding to the medical entity identifier. Further, a medical data table including the target medical data is constructed based on the medical data sub-table. Finally, the medical data table can be returned to the sender.
[0069] A method for merging target medical data corresponding to the same medical entity identifier to obtain a sub-table of medical data corresponding to the medical entity identifier can be to align the fields in the records corresponding to the target entity identifier and then concatenate each record. For some medical data that can be aggregated, aggregation processing can also be performed first. Of course, a method for merging target medical data corresponding to the same medical entity identifier to obtain a sub-table of medical data corresponding to the medical entity identifier can also be to store all medical data corresponding to the same medical entity in a single record. This record involves all fields corresponding to that entity. In some embodiments, the merging method can be performed according to keywords such as join or full join in the query statement.
[0070] A method for constructing a medical data table including the target medical data based on the medical data sub-table may involve concatenating the fields of the medical data sub-table. Medical data for the same field in different entities can be stored in the same column. Correspondingly, if a medical entity does not have corresponding medical data for another medical entity, the medical data in the corresponding field can be set as control.
[0071] Example devices, electronic devices, storage media, and software
[0072] Please see Figure 5 One embodiment of this specification also provides a medical data query device. The medical data query device may include: a receiving module, a generating module, a sending module, and a feedback module.
[0073] A receiving module is configured to receive a first query instruction; wherein the first query instruction includes a first instruction parameter for indicating target medical data.
[0074] The generation module is used to generate a second query instruction based on the mapping result obtained by the first instruction parameter according to the preset mapping relationship between the first instruction parameter and the second instruction parameter; wherein the second query instruction is used to indicate the target field and target record of the medical data in the horizontal table of the target database, wherein at least one field in the horizontal table includes different categories of medical data.
[0075] The sending module is used to send the second query instruction to the database to obtain the target medical data that is in the target field and in the target record.
[0076] The feedback module is used to send the target medical data back to the sender of the first query command.
[0077] Please see Figure 6 One embodiment of this specification also provides a medical data query device, which may include a receiving module, an extraction module, and a feedback module.
[0078] A receiving module is configured to receive a second query instruction for target medical data; wherein the second query instruction is configured to indicate the target fields and target records of the target medical data in a horizontal table of a target database; wherein at least one field in the horizontal table includes different categories of medical data.
[0079] The extraction module is used to extract target medical data that is located in the target field and in the target record from the target database based on the second query instruction.
[0080] The feedback module is used to send the target medical data back to the sender of the second query command.
[0081] The specific functions and effects of the medical data query device can be explained by referring to other embodiments in this specification, and will not be repeated here. Each module in the medical data query device can be implemented entirely or partially through software, hardware, or a combination thereof. Each module can be embedded in or independent of the processor in the computer device in hardware form, or it can be stored in the memory of the computer device in software form, so that the processor can call and execute the operations corresponding to each module.
[0082] Please see Figure 7 The embodiments of this specification also provide a computer device, including a memory and a processor, wherein the memory stores a computer program, characterized in that the processor executes the computer program to implement the medical data query method in any of the above embodiments.
[0083] This specification also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a computer, causes the computer to perform the medical data query method in any of the above embodiments.
[0084] This specification also provides a computer program product containing instructions that, when executed by a computer, cause the computer to perform the medical data query method in any of the above embodiments.
[0085] It is understood that the specific examples in this document are only intended to help those skilled in the art better understand the embodiments described herein, and are not intended to limit the scope of the invention.
[0086] It is understood that in the various embodiments described in this specification, the sequence number of each process does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments described in this specification.
[0087] It is understood that the various implementation methods described in this specification can be implemented individually or in combination, and the implementation methods in this specification are not limited in this respect.
[0088] Unless otherwise stated, all technical and scientific terms used in the embodiments of this specification have the same meaning as commonly understood by one of ordinary skill in the art. The terminology used in this specification is for the purpose of describing particular embodiments only and is not intended to limit the scope of this specification. The term "and / or" as used in this specification includes any and all combinations of one or more of the associated listed items. The singular forms "a," "the," and "the" as used in the embodiments of this specification and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise.
[0089] It is understood that the processor in the embodiments of this specification can be an integrated circuit chip with signal processing capabilities. In implementation, each step of the above method embodiments can be completed by integrated logic circuits in the processor's hardware or by instructions in software form. The processor can be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this specification. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the methods disclosed in the embodiments of this specification can be directly implemented by a hardware decoding processor, or by a combination of hardware and software modules in the decoding processor. The software modules can reside in random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, or other mature storage media in the art. This storage medium is located in memory; the processor reads information from the memory and, in conjunction with its hardware, completes the steps of the above methods.
[0090] It is understood that the memory in the embodiments of this specification may be volatile memory or non-volatile memory, or may include both volatile and non-volatile memory. Non-volatile memory may be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory may be random access memory (RAM). It should be noted that the memory in the systems and methods described herein is intended to include, but is not limited to, these and any other suitable types of memory.
[0091] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this specification.
[0092] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the aforementioned method implementations, and will not be repeated here.
[0093] In the several embodiments provided in this specification, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.
[0094] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment, depending on actual needs.
[0095] In addition, the functional units in the various embodiments of this specification can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0096] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solutions of this specification, in essence, or the parts that contribute to the prior art, or parts of the technical solutions, can be embodied in the form of software products. These computer software products are stored in a storage medium and include several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this specification. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0097] The above description is merely a specific embodiment of this specification, but the scope of protection of this invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in this specification should be included within the scope of protection of this specification. Therefore, the scope of protection of this invention should be determined by the scope of the claims.
Claims
1. A method for querying medical data, characterized in that, The method is applied to a data middle platform and includes: Receive a first query instruction; wherein the first query instruction includes a first instruction parameter for indicating target medical data; the first instruction parameter includes a first field identifier for indicating the field of the target medical data in a medical form, a target form identifier for indicating the target medical form to which the target medical data belongs, and a target entity identifier for indicating the medical entity corresponding to the target medical data; multiple preset mapping relationships between first instruction parameters and second instruction parameters are set for different medical forms; Based on the target form identifier, the target preset mapping relationship is matched from multiple preset mapping relationships; According to the target preset mapping relationship, the field identifier of the first field identifier relative to the target field in the horizontal table of the target database is determined as the second field identifier; the second field identifier is used as the second instruction parameter; the second field identifier is used to indicate the target field; wherein, the horizontal table also includes a first identifier field storing entity identifiers and a data field storing medical data; the entity identifier is used to indicate the medical entity corresponding to the medical data belonging to the same record in the horizontal table as the entity identifier; the target entity identifier is also used to indicate the target record of the target medical data in the horizontal table of the target database; A second query instruction is generated based on the second field identifier and the target entity identifier; wherein the second query instruction is used to indicate the target field and target record of the medical data in the horizontal table of the target database; wherein at least one field in the horizontal table includes different categories of medical data; The second query instruction is sent to the target database to obtain the target medical data that is in the target field and in the target record; The target medical data is then fed back to the sender of the first query command.
2. A medical data query device, characterized in that, The device includes: A receiving module is configured to receive a first query instruction; wherein the first query instruction includes a first instruction parameter for indicating target medical data; the first instruction parameter includes a first field identifier for indicating the field of the target medical data in a medical form, a target form identifier for indicating the target medical form to which the target medical data belongs, and a target entity identifier for indicating the medical entity corresponding to the target medical data; multiple preset mapping relationships between first instruction parameters and second instruction parameters are set for different medical forms; A generation module is used to match a target preset mapping relationship among multiple preset mapping relationships based on the target form identifier; determine the field identifier of the target field in the horizontal table of the target database relative to the first field identifier according to the target preset mapping relationship, as the second field identifier; the second field identifier is used as the second instruction parameter; the second field identifier is used to indicate the target field; the horizontal table also includes a first identifier field storing entity identifiers and a data field storing medical data; the entity identifier is used to indicate the medical entity corresponding to the medical data belonging to the same record in the horizontal table as the entity identifier; the target entity identifier is also used to indicate the target record of the target medical data in the horizontal table of the target database; a second query instruction is generated based on the second field identifier and the target entity identifier; wherein the second query instruction is used to indicate the target field and target record of the medical data in the horizontal table of the target database; wherein at least one field in the horizontal table includes different categories of medical data; The sending module is used to send the second query instruction to the database to obtain the target medical data that is in the target field and in the target record; The feedback module is used to send the target medical data back to the sender of the first query command.
3. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the method of claim 1.
4. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the method of claim 1.
Citation Information
Patent Citations
Data query method, device and system
CN112015754A
Mapping table management method, memory control circuit unit and memory storage device
CN114328297A