Query processing device and query processing method
By using historical information and subquery decomposition technology, the efficiency problem of multi-organization constraint processing in federal queries is solved, and efficient query constraint judgment and calculation cost reduction are achieved.
Patent Information
- Application Number
- JP2023171583
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2023-10-02
- Publication Date
- 2025-04-14
AI Technical Summary
When using federal query, it is difficult for the prior art to effectively handle constraints of external databases managed by multiple organizations, resulting in increased computational costs and it is impossible to efficiently determine whether the query complies with the constraints of each organization.
Through historical information and subquery decomposition technology, we can judge whether the input query complies with the rules of each organization, and adopt the subquery decomposition and scoring mechanism to optimize the query transmission and rule inspection process to reduce the calculation cost.
It effectively reduces the calculation cost of judging whether the query complies with the constraints, improves the efficiency of query processing, and reduces the consumption of computing resources for each organization.
Smart Images

Figure 2025062474000001_ABST
Abstract
Description
[Technical field]
[0001] The present disclosure relates to a query processing device and a query processing method. [Background technology]
[0002] Data collection technology that collects and analyzes various data is important for understanding the current situation and predicting the future, and is used for data-driven decision-making, etc. However, in order to use data, it is necessary to comply with the constraints imposed on the data.
[0003] Patent Document 1 discloses a technique for determining whether or not a query from a user complies with constraints imposed on data when the query is operated on data stored in a database. In this technique, statistical information such as the k value of data generated by an operation in response to the query is estimated from the original data in the database, and whether or not the data complies with the constraints is determined based on the statistical information. [Prior art documents] [Patent documents]
[0004] [Patent Document 1] JP 2022-137857 A Summary of the Invention [Problem to be solved by the invention]
[0005] When a federated query, which can treat external databases managed by multiple organizations as if they were internal databases, is used as a query for manipulating data, there is a problem in that the technique described in Patent Document 1 cannot be applied because the method of estimating statistical information on data may not be able to handle constraints that are individually defined by each organization.
[0006] In this case, it is necessary to inquire of each organization whether the query complies with the constraints individually defined by each organization, which results in using the computational resources of all organizations, resulting in a problem of high computational costs for determining whether the query complies with the constraints.
[0007] An object of the present disclosure is to provide a query processing device and management method capable of reducing the calculation cost for determining whether or not a query complies with a constraint. [Means for solving the problem]
[0008] A query processing device according to one aspect of the present disclosure is a query processing device that determines whether an input query requesting an operation on multiple data managed by each of multiple organizations complies with constraints imposed on the data, and includes a division unit that generates multiple sub-queries by dividing the input query for each organization; a calculation unit that calculates, for each organization, an organization score that evaluates an organization-specific risk, which is the risk that the sub-query will be determined to not comply with the organization rule of the organization corresponding to the sub-query, based on historical information regarding a judgment performance of whether or not the input query complies with the organization rule, which is the constraint for each organization; a sub-query control unit that transmits the sub-queries to a confirmation device that confirms whether or not the sub-query complies with the organization rule of the organization corresponding to the sub-query in order according to a transmission order according to the organization score, and receives response information to the sub-queries from the confirmation device in order; and a determination unit that uses the response information to determine whether or not the input query complies with the constraint. Effect of the Invention
[0009] The present invention makes it possible to reduce the computational cost of checking whether a query complies with constraints. [Brief description of the drawings]
[0010] [Figure 1]FIG. 1 is a diagram illustrating a configuration of a query processing device according to an embodiment of the present disclosure. [Diagram 2] 1 is a flowchart for explaining an overall process of a query processing device according to an embodiment of the present disclosure. [Diagram 3] 10 is a flowchart illustrating an example of a country regulation determination process. [Figure 4] FIG. 13 is a diagram illustrating an example of a policy setting screen. [Diagram 5] 13 is a flowchart illustrating an example of an organizational rule determination process. [Figure 6] FIG. 11 is a diagram illustrating an example of a subquery generation process. [Figure 7] FIG. 11 is a diagram illustrating an example of a query score calculation process. [Figure 8] FIG. 11 is a diagram illustrating an example of rank information. [Figure 9] 11 is a flowchart illustrating an example of a transmission method determination process. [Figure 10] FIG. 13 is a diagram illustrating an example of a transmission order list. [Figure 11] FIG. 2 is a diagram illustrating a hardware configuration of a query processing device according to an embodiment of the present disclosure. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0011] Hereinafter, embodiments of the present disclosure will be described with reference to the drawings.
[0012] Fig. 1 is a diagram illustrating a configuration of a query processing device according to an embodiment of the present disclosure. The query processing device 100 illustrated in Fig. 1 is a device that performs a compliance check to determine whether an input query, which is a query requesting an operation on data, complies with a constraint (compliance) imposed on the data. The compliance check includes a country regulation check to determine whether the data complies with the regulations of the target country in which the data is handled, and an organization rule check to determine whether the data complies with organization rules stipulated by the organization that manages the data. The organization is, for example, a hospital, but is not limited to this example.
[0013] Specifically, the query processing device 100 has a country regulation determination unit 1, a country compliance status storage unit 2, a history storage unit 4, a non-compliance ratio calculation unit 5, a non-compliance determination time calculation unit 6, a query division unit 3, a score calculation unit 7, a score information storage unit 8, a subquery control unit 9, an organization-specific compliance status storage unit 10, an overall determination unit 11, and an overall compliance status storage unit 12.
[0014] The country restriction determination unit 1 performs a country restriction check to determine whether the input query complies with the country restriction of the target country. In this embodiment, the input query is a federated query that can treat an external database managed by each organization as an internal database, but is not limited to this. The country restriction check is realized by a data flow check using a data flow policy that describes data that permits or prohibits data transfer within a country or between multiple countries. The target country is the country from which data is transferred and the country to which data is transferred. When data is transferred within a country, the country from which data is transferred and the country to which data is transferred are the same.
[0015] The country compliance status storage unit 2 stores country compliance status information indicating the determination result (i.e., whether or not the input query complies with the country regulation) by the country regulation determination unit 1. Here, the country compliance status information indicates "Compliant" when the input query complies with the country regulation, and indicates "Non-compliant" when the input query does not comply with the country regulation.
[0016] The query division unit 3, the history storage unit 4, the non-compliance ratio calculation unit 5, the non-compliance judgment time calculation unit 6, the score calculation unit 7, the score information storage unit 8 and the subquery control unit 9 constitute a query control unit 50 that performs an organizational rule check to determine whether an input query complies with the organizational rules of each organization.
[0017] The query division unit 3 divides the input query into a plurality of sub-queries that request operations on the data of each organization.
[0018] The history storage unit 4, the non-compliance ratio calculation unit 5, the non-compliance determination time calculation unit 6, and the score calculation unit 7 constitute a calculation unit that calculates an organization score that evaluates an organization-specific risk, which is the risk that a sub-query divided by the query division unit 3 will be determined to not comply with the organization rules. The organization score is calculated for each organization.
[0019] The history storage unit 4 stores, for each organization that manages data, history information on the results of organizational rule checks that determine whether a subquery requesting an operation on data of the organization complies with organizational rules defined by the organization. The organizational rules include individual rules for each source data that is the data that is the target of an operation requested by the subquery. In this embodiment, each data in a database managed by an organization is table data, and the source data is a column of the table data, but is not limited to this example.
[0020] The non-compliance ratio calculation unit 5 calculates, for each organization, the ratio at which the sub-queries corresponding to the organization are determined to not comply with the organization rule as the non-compliance ratio based on the history information stored in the history storage unit 4. More specifically, for each individual rule included in the organization rule, the non-compliance ratio calculation unit 5 calculates the ratio at which the sub-queries are determined to not comply with the individual rule relative to the number of times that a column corresponding to the individual rule is the target of an operation by the sub-query.
[0021] The non-compliance determination time calculation unit 6 calculates, for each organization, the time required for a subquery to be determined to be a non-compliant query that does not comply with the organization rules, as a non-compliance determination time, based on the history information stored in the history storage unit 4. The non-compliance determination time is specifically a statistical value (e.g., an average value) of the past required times. The non-compliance determination time differs, for example, depending on the type of database used by the organization. For example, if the organization is a hospital, it differs depending on whether the database is an NDB (National Date Base: database of information on specific health checkups, etc.) or a KDB (Kokuho Data Base: national health insurance database).
[0022] The score calculation unit 7 calculates, for each organization, an organization score that evaluates an organization-specific risk, which is a risk that the subquery generated by the query division unit 3 will be determined to not comply with the organization rules, based on the non-compliance ratio of each organization calculated by the non-compliance ratio calculation unit 5 and the non-compliance judgment time of each organization calculated by the non-compliance judgment time calculation unit 6. In addition, the score calculation unit 7 calculates a query score that evaluates the risk that the input query will be determined to not comply with the organization rules, based on the non-compliance ratio of each organization calculated by the non-compliance ratio calculation unit 5.
[0023] The score information storage unit 8 stores the query score and the organization score calculated by the score calculation unit 7.
[0024] Subquery control unit 9 determines a subquery transmission method based on the query score stored in score information storage unit 8, and transmits the subqueries according to the transmission method. The transmission method includes a parallel transmission method in which all subqueries are transmitted together, and a sequence transmission method in which subqueries are transmitted in order according to the organization score of each organization.
[0025] In this case, the destination of the subquery is the rule confirmation device 110, which is a server provided for each organization. Upon receiving the subquery, the rule confirmation device 110 of each organization checks whether the subquery complies with the organization rule of its own organization, and returns the check result to the query processing device 100 as response information.
[0026] The organization-specific compliance status storage unit 10 stores organization-specific compliance status information indicating, for each organization, the response information from the rule checking device 110 (i.e., whether or not the subquery complies with the organization rule). Here, the organization-specific compliance status information indicates "Compliant" for each organization if the subquery complies with the organization rule, and indicates "Non-compliant" for each organization if the subquery does not comply with the organization rule.
[0027] The comprehensive judgment unit 11 judges whether or not the input query complies with the constraints, based on the country compliance state information stored in the country compliance state storage unit 2 and the organization-specific compliance state information stored in the organization-specific compliance state storage unit 10. Specifically, when the country compliance state information indicates "Compliant" and the organization-specific compliance state information indicates "Compliant" for all organizations, the comprehensive judgment unit 11 judges that the input query complies with the constraints, and otherwise judges that the input query does not comply with the constraints.
[0028] The overall compliance status storage unit 12 stores overall compliance status information indicating the judgment result (whether the input query complies with the constraints or not) by the overall judgment unit 11. The overall compliance status information may be output to the transmission source of the input query, etc.
[0029] FIG. 2 is a flowchart for explaining the overall processing of the query processing device 100. As shown in FIG.
[0030] In the overall processing, first, the country regulation determination unit 1 performs a country regulation check to determine whether the input query complies with the country regulation, and executes a country regulation determination process (see Figure 3) in which country compliance status information indicating the determination result is stored in the country compliance status storage unit 2 (Step A).
[0031] Next, the query control unit 50 executes an organizational rule check to determine whether the input query complies with the organizational rules of each organization, and executes an organizational rule determination process (see FIG. 5) to store organization-specific compliance status information indicating the determination result (step B).
[0032] Then, the comprehensive judgment unit 11 executes a comprehensive judgment process to judge whether the input query is compliant or not based on the country compliance status information and the organization-specific compliance status information, and stores comprehensive compliance status information indicating the judgment result in the comprehensive compliance status storage unit 12 (step C), and then terminates the process.
[0033] FIG. 3 is a flowchart for explaining an example of the national restriction determination process in step A of FIG.
[0034] In the country restriction determination process, the country restriction determination unit 1 first acquires an input query (step A1). For example, the country restriction determination unit 1 acquires an input query transmitted from an external device such as a client terminal operated by a user who uses the query processing device 100.
[0035] The country restriction determination unit 1 uses a Structured Query Language (SQL) parser to analyze (parse) the input query and identify operation items related to operations requested by the input query (step A2). The operation items include operation target information that identifies source data that is the target of the operation requested by the input query, the country from which the source data is transferred, the country to which the source data is transferred, whether or not the source data needs to be aggregated, and whether or not the source data needs to be masked. In this embodiment, the source data is a column as described above, and the operation target information includes, for example, a value that identifies the column (such as a column name), a value that identifies a table that has the column (such as a table name), and a value that identifies an organization that manages the table. The value that identifies the organization may be a location value that indicates the location of the organization, or the like.
[0036] The country restriction determination unit 1 determines whether the source data conforms to the data flow policy for each source data based on the operation items (step A3). For example, when the data flow policy describes data that is permitted to be transferred, the country restriction determination unit 1 determines that the source data conforms to the data flow policy if each operation item (operation target information, source country, destination country, whether aggregation is required, and whether masking is required) is all described in the data flow policy.
[0037] The national regulation determination unit 1 determines whether the input query complies with the national regulation based on the determination result for each source data by the process of step A3 (step A4). Specifically, the national regulation determination unit 1 determines that the input query complies with the national regulation if all source data complies with the data flow policy, and otherwise determines that the input query does not comply with the national regulation.
[0038] Then, the country regulation determination unit 1 generates country compliance status information indicating the determination result in step A4, stores it in the country compliance status storage unit 2 (step A5), and ends the process.
[0039] If the country compliance status information becomes "Non-compliant" in the above process, the overall compliance status information becomes "Non-compliant" in the overall determination process in step C, regardless of the processing result of the organizational rule determination process in step B of Fig. 2. Therefore, if the country compliance status information becomes "Non-compliant", the process in step B may be skipped.
[0040] The data flow policy used in step A3 is set in advance by an administrator of the query processing device 100 or the like. Fig. 4 is a diagram showing an example of a policy setting screen for setting a data flow policy. The policy setting screen 400 shown in Fig. 4 has interfaces 401 to 407 for setting item values of each item of the data flow policy (organization, table, column, source country, destination country, whether aggregation is required, and whether masking is required), and a confirmation button 408 for confirming the item values set in the interfaces 401 to 407 as the data flow policy.
[0041] FIG. 5 is a flowchart for explaining an example of the organizational rule determination process in step B of FIG.
[0042] In the organizational rule determination process, first, the query division unit 3 analyzes the input query using the SQL parser, and extracts attribute information of the input query from the input query (step B1). The attribute information of the input query includes operation target information.
[0043] The query division unit 3 performs location analysis to identify the correspondence between the location of the organization and the source data based on the location table indicating the correspondence between the location of the organization and the data managed by the organization and the attribute information extracted in step B1 (step B2).
[0044] The query division unit 3 divides the input query into sub-queries for each organization based on the result of the location analysis (step B3).
[0045] FIG. 6 is a diagram for explaining an example of the subquery generation process for generating subqueries in steps B1 to B3. In the example of FIG. 6, a federated query 600 including a SELECT statement as an input query and a location table 601 are shown. The variables of the SELECT statement, which are attribute information of the federated query 600, include information for identifying the organization managing the source data, the column which is the source data, and the table having the column. Specifically, in FIG. 6, character strings P and Q included in the variables are location values indicating the location of the organization, A and B are table values indicating the table, and a, aa, Sal, b, and bb are column values indicating the columns. The location table 601 shows the correspondence between the character strings P and Q indicating the location of the organization, the character strings A and B indicating the table managed by the organization, and the character strings a, aa, Sal, b, and bb indicating the columns of the table.
[0046] In step B1, attribute information 602 is extracted from the federated query 600, and in step B2, a correspondence 603 between the locations of organizations and the attribute information is identified based on the location table 601 and the attribute information 602. Then, in step B3, the federated query 600 is divided into sub-queries 604 for each location of the organizations based on the correspondence 603.
[0047] Returning to the explanation of Fig. 5, the score calculation unit 7 executes a query score calculation process to calculate a query score for the input query based on the non-compliance ratio of each organization calculated by the non-compliance ratio calculation unit 5, and stores the query score in the score information storage unit 8 (step B4).
[0048] FIG. 7 is a diagram illustrating an example of the query score calculation process for calculating the query score in step B4.
[0049] 7, in the query score calculation process, the score calculation unit 7 first identifies one or more columns Cij that are targets of operations in each of multiple subqueries Qi (i=1 to n) generated from the input query Q. Then, the score calculation unit 7 acquires a non-compliance ratio Fij in which the operations required in the subqueries Qi do not comply with individual rules Rij, which are organizational rules for each column Cij, from the non-compliance ratio calculation unit 5, and calculates a value obtained by applying a sigmoid function to the sum of these values as the query score S. Here, the subscript i identifies the organization, and the subscript j identifies one or more columns that are targets of operations in subqueries corresponding to the same organization.
[0050] Returning to the explanation of Fig. 5, the score calculation unit 7 executes a calculation process to calculate an organization score for each organization based on the non-compliance ratio calculated by the non-compliance ratio calculation unit 5 and the non-compliance judgment time calculated by the non-compliance judgment time calculation unit 6, and stores the organization score in the score information storage unit 8 (step B5).
[0051] In the process of calculating the organization score, the score calculation unit 7 calculates, for example, for each organization, the organization score by multiplying the non-compliance judgment time gi corresponding to that organization by the sum hi of the non-compliance ratios Fij for the individual rules Rij included in the organization rules of that organization (gi×hi) and applying a sigmoid function to the result.
[0052] Furthermore, the score calculation unit 7 stores the organization scores in the score information storage unit 8 as rank information in which the organizations are arranged in descending order of their organization scores.
[0053] Fig. 8 is a diagram showing an example of rank information indicating an organization score. Rank information 800 shown in Fig. 8 includes fields 801 to 802. Field 801 stores a hospital name as identification information for identifying a hospital, which is an example of an organization. Field 802 stores an organization score for the hospital. Furthermore, in rank information 800, each record 703 is sorted in descending order of organization score.
[0054] Returning to the explanation of Fig. 5, subquery control unit 9 executes a transmission method determination process (see Fig. 9) for determining a transmission method of a subquery to each organization based on the query score stored in score information storage unit 8 (step B6).
[0055] Subquery control unit 9 transmits the subquery to rule confirmation device 110 of each organization based on the determined transmission method. Thereafter, subquery control unit 9 receives response information, which is a confirmation result indicating whether or not the subquery complies with the organization rule, from rule confirmation device 110, and stores the response information as organization-specific compliance status information in organization-specific compliance status storage unit 10 (step B7), and ends the process.
[0056] In step B7, if the transmission method is the sequence transmission method, subquery control unit 9 transmits subqueries in order according to the transmission order corresponding to the rank information stored in score information storage unit 8. At this time, when subquery control unit 9 receives response information to the previous subquery, it transmits the next subquery. In this case, when non-compliant response information indicating "Non-compliant" is received, the overall compliance status information becomes "Non-compliant" in the overall judgment process of step C in Fig. 2, regardless of the content of the response information from other organizations. For this reason, subquery control unit 9 may stop transmitting subsequent subqueries.
[0057] FIG. 9 is a flowchart for explaining an example of the transmission method determination process in step B6.
[0058] In the transmission method determination process, the subquery control unit 9 first determines whether the query score S of the input query is equal to or less than a first threshold (step S1). In the example of FIG. 8, the first threshold is set to 0.3, but is not limited to this example. Note that in this embodiment, the higher the query score S, the higher the risk that the input query will be determined to not comply with the organizational rules. For this reason, the query score S being equal to or less than the first threshold corresponds to the risk being equal to or less than a predetermined standard.
[0059] If the query score is greater than the first threshold (step S1: No), the subquery control unit 9 determines the transmission method to be the parallel transmission method (step S2), and ends the process.
[0060] On the other hand, if the query score is equal to or less than the first threshold (step S1: Yes), the subquery control unit 9 determines the transmission method to be the sequence transmission method (step S3).Then, the subquery control unit 9 selects, from among the records that have not yet been selected, the record with the highest organization score based on the rank information as the target record (step S4).
[0061] The subquery control unit 9 determines whether the organization score Si of the target record is equal to or less than a second threshold (step S5). In the example of FIG. 8, the second threshold is 0.7, but is not limited to this example. In this embodiment, the higher the organization score Si, the higher the risk that the subquery will be determined to not comply with the organization rule. For this reason, an organization score Si equal to or less than the second threshold corresponds to the risk being equal to or less than a predetermined standard.
[0062] If the organization score is greater than the second threshold (step S4: No), the subquery control unit 9 adds the organization of the target record to the end of the transmission order list that indicates the transmission order of the subqueries (step S5). Then, the subquery control unit 9 determines whether all organizations have been added to the transmission order list (step S6). If not all organizations have been added (step S6: No), the subquery control unit 9 returns to the processing of step S4, and if all organizations have been added (step S6: Yes), the processing ends.
[0063] If the organization score is equal to or less than the second threshold (step S4: Yes), sub-query control unit 9 adds all the remaining organizations to the end of the transmission order list (step S7), and ends the process.
[0064] By the above process, when the transmission method is the sequential transmission method, the transmission order list stores organizations whose organizational risk is greater than a predetermined standard in descending order of organizational risk, followed by organizations whose organizational risk is less than the predetermined standard in the same transmission order. Therefore, the subquery control unit 9 transmits high prediction subqueries, which are subqueries corresponding to organizations whose organizational risk is greater than a predetermined standard, in descending order of organizational risk, and transmits subqueries corresponding to organizations whose organizational risk is equal to or less than the standard all at once after transmitting the high prediction subqueries.
[0065] Fig. 10 is a diagram showing an example of a transmission order list. In the transmission order list 1000 shown in Fig. 10, organizations are arranged in the order of the transmission order of the subquery corresponding to the organization, and at the end, multiple organizations added in step S7 are stored as having the same transmission order.
[0066] FIG. 11 is a diagram illustrating a hardware configuration of the query processing device 100. As shown in FIG.
[0067] As shown in FIG. 11, the query processing device 100 has a processor 21, a main memory 22, a recording device 23, an input device 24, a display device 25, and a communication device 26, and is realized by a computer system that is connected via a bus 27.
[0068] The recording device 23 is a device for recording data in a writable and readable manner, and records the program that defines the operation of the processor 21, and various information generated and used by the program. For example, the recording device 23 stores history information, country compliance status information, compliance status information by organization, overall compliance status information, query scores, organization scores, etc.
[0069] The processor 21 is, for example, a CPU (Central Processing Unit), and is a control unit that reads a program recorded in the recording device 23 into the main memory 22 and executes processing according to the program using the main memory 22. The components and functions shown in FIG. 1 are realized by the processor 21. The input device 24 is a device into which various information is input by an operator of the query processing device 100, and the information is used for processing by the processor 21. The display device 25 is a device that displays various information. The communication device 26 communicates with other devices (such as the sender of the input query and the rule confirmation device 200) and transmits and receives various information.
[0070] At least a part of the processing by the processor 21 may be realized by a hardware circuit (for example, an Application Specific Integrated Circuit (ASIC) or a Field-Programmable Gate Array (FPGA)).
[0071] As described above, according to this embodiment, the query division unit 3 generates a plurality of sub-queries by dividing the input query by organization. The score calculation unit 7 calculates, for each organization, an organization score that evaluates an organization-specific risk, which is a risk that a sub-query is determined not to comply with the organization rule of the organization corresponding to the sub-query, based on history information on a judgment result for each organization in which it is judged whether the input query complies with the organization rule of each organization. The sub-query control unit 9 transmits the sub-queries to the rule confirmation device 200 in order according to a transmission order according to the organization score, and receives response information to the sub-queries from the rule confirmation device 200 in order. The overall judgment unit 11 uses the response information to judge whether the input query complies with the constraint.
[0072] Therefore, it is possible to determine whether or not subqueries comply with the organizational rules in descending order of risk of being determined not to comply with the organizational rules, which makes it possible to suppress unnecessary subquery determinations, thereby reducing the calculation cost for determining whether or not a query complies with a constraint.
[0073] In addition, in this embodiment, when the subquery control unit 9 receives non-compliance response information indicating that the subquery does not comply with the organizational rules, the subquery control unit 9 stops sending the subquery. When the non-compliance response information is received, the comprehensive determination unit 11 determines that the input query does not comply with the constraints. In this case, it is possible to more appropriately reduce the calculation cost for determining whether the query complies with the constraints.
[0074] In this embodiment, the score calculation unit 7 calculates, for each organization, a non-compliance determination time required for the input query to be determined as not complying with the organization rule and a non-compliance ratio at which the input query is determined as not complying with the organization rule based on the history information, and calculates the organization score based on the non-compliance determination time and the non-compliance ratio. In this case, it is possible to more appropriately reduce the calculation cost for determining whether or not a query complies with a constraint.
[0075] In addition, in this embodiment, the subquery control unit 9 transmits high prediction subqueries, which are subqueries corresponding to organizations whose organizational risk is higher than a predetermined standard, in descending order of organizational risk, and transmits subqueries corresponding to organizations whose organizational risk is equal to or lower than the standard in a batch after transmitting the high prediction subqueries. In this case, it is possible to transmit subqueries that are unlikely to be determined as not complying with the organizational rules in a batch after transmitting subqueries that are likely to be determined as not complying with the organizational rules, thereby reducing calculation costs and suppressing an increase in calculation time for determining whether a query complies with a constraint.
[0076] Furthermore, in this embodiment, the score calculation unit 7 calculates a query score that evaluates an overall risk, which is a risk that the input query is determined not to comply with the constraints, based on the history information. If the overall risk is equal to or less than a predetermined standard based on the query score, the subquery control unit 9 transmits the subqueries in order according to the transmission order, and if the overall risk is greater than the standard, transmits the subqueries all at once. In this case, if the risk that the input query is determined to comply with the constraints is low, it becomes possible to transmit the subqueries all at once, thereby reducing the calculation cost and suppressing an increase in the calculation time for determining whether the query complies with the constraints.
[0077] In this embodiment, the score calculation unit 7 calculates, for each organization, a percentage of data that is determined to be non-compliant with an individual rule, which is an organizational rule corresponding to data that is the target of an operation requested by a subquery, based on the history information, and calculates the query score based on the total value of each percentage. In this case, the query score can be set to a value that appropriately evaluates the overall risk.
[0078] In this embodiment, the attribute information specifying the data to be operated on in the input query includes a location value indicating the location where the organization is established. The query division unit 3 divides the input query into sub-queries based on the location value. In this case, it becomes possible to appropriately generate the sub-queries.
[0079] The national restriction determination unit 1 determines whether the input query complies with national restrictions, which are restrictions on data set by the target country. The overall determination unit 11 further uses the determination result by the national restriction determination unit 1 to determine whether the input query complies with the restrictions. In this case, restrictions imposed by the country separately from the organization can also be handled.
[0080] The above-described embodiments of the present disclosure are illustrative examples of the present disclosure, and are not intended to limit the scope of the present disclosure to only these embodiments. A person skilled in the art can implement the present disclosure in various other forms without departing from the scope of the present disclosure. [Explanation of symbols]
[0081] 1: Country regulation determination unit 2: Country compliance status storage unit 3: Query division unit 4: History storage unit 5: Non-compliance ratio calculation unit 6: Non-compliance determination time calculation unit 7: Score calculation unit 8: Score information storage unit 9: Subquery control unit 10: Organization-specific compliance status storage unit 11: Overall determination unit 12: Overall compliance status storage unit 50: Query control unit 100: Query processing device 110: Rule confirmation device
Claims
1. 1. A query processing device that determines whether an input query requesting an operation on a plurality of data managed by each of a plurality of organizations complies with constraints imposed on the data, comprising: a division unit that generates a plurality of sub-queries by dividing the input query for each of the organizations; a calculation unit that calculates, for each organization, an organization score that evaluates an organization-specific risk, which is a risk that the subquery will be determined to not comply with the organizational rule of the organization corresponding to the subquery, based on history information on a determination result of whether or not the input query complies with the organizational rule, which is the constraint for each organization; and a subquery control unit that transmits the subqueries to a confirmation device that confirms whether the subqueries comply with the organization rule of the organization corresponding to the subqueries in a transmission order according to the organization score, and receives response information to the subqueries from the confirmation device in order; a determination unit that determines whether the input query complies with the constraints using the response information.
2. the sub-query control unit, when receiving, as the response information, non-compliance response information indicating that the sub-query does not comply with the organizational rule, stops transmitting the sub-query; The query processing device according to claim 1 , wherein the determination unit determines that the input query does not comply with the constraint when the non-compliant response information is received.
3. 2. The query processing device of claim 1, wherein the calculation unit calculates, for each organization based on the history information, a required time required for a subquery corresponding to the organization to be determined to not comply with the organization rule and a percentage of the subqueries corresponding to the organization that are determined to not comply with the organization rule, and calculates the organization score based on the required time and the percentage.
4. 2. The query processing device according to claim 1, wherein the subquery control unit transmits highly predictive subqueries, which are subqueries corresponding to organizations whose organizational risk is greater than a predetermined standard, in order of increasing organizational risk based on the organizational score, and transmits subqueries corresponding to organizations whose organizational risk is equal to or less than the standard in a batch after transmitting the highly predictive subqueries.
5. the calculation unit calculates a query score by evaluating an overall risk, which is a risk that the input query will be determined to not comply with the constraint, based on the history information; and 2. The query processing device according to claim 1, wherein the subquery control unit transmits the subqueries in order according to the transmission order if the overall risk is equal to or less than a predetermined standard based on the query score, and transmits the subqueries all at once if the overall risk is greater than the standard.
6. 6. The query processing device according to claim 5, wherein the calculation unit calculates, for each of the organizations, a percentage of data that is determined to be non-compliant with an individual rule that is an organizational rule corresponding to the data that is the target of the operation requested in the subquery, based on the history information, and calculates the query score based on a total value of each percentage.
7. the attribute information specifying the data to be operated on in the input query includes a location value indicating a place where the organization is established; The query processing device according to claim 1 , wherein the dividing unit divides the input query into the sub-queries based on the location value.
8. a national regulation determination unit that determines whether the input query complies with a national regulation, which is the restriction stipulated in a target country related to the data; The query processing device according to claim 1 , wherein the determination unit determines whether or not the input query complies with the constraints by further using a determination result by the country restriction determination unit.
9. 1. A query processing method for a query processing device that determines whether an input query requesting an operation on a plurality of data managed by each of a plurality of organizations complies with constraints imposed on the data, the method comprising: generating a plurality of sub-queries by dividing the input query by the organizations; calculating, for each organization, an organization score that evaluates an organization-specific risk, which is a risk that the subquery will be determined not to comply with the organizational rule of the organization corresponding to the subquery, based on history information on a determination result of whether or not the input query complies with an organizational rule, which is the constraint for each organization; transmitting the sub-queries to a verification device that verifies whether the sub-queries comply with the organizational rules of the organizations corresponding to the sub-queries in a transmission order according to the organizational scores; receiving response information to the sub-queries from the verification device in sequence; The method of query processing further comprising: using the response information to determine whether the input query complies with the constraints.
Citation Information
Patent Citations
Data management device, data management system and data management method
JP2022137857A