Data verification method and device, equipment, storage medium and program product

Through scripts, the execution parameters of slow query statements in the database are obtained and analyzed, and the problem content is quickly positioned and marked, solving the problem of low positioning efficiency of slow query statements and improving operation and maintenance efficiency.

CN119415553APending Publication Date: 2025-02-11CHINA CONSTRUCTION BANK +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411573170.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-06
Publication Date
2025-02-11

AI Technical Summary

Technical Problem

The problem positioning efficiency of slow query statements is low, which causes operation and maintenance personnel to view a large amount of relevant content, which takes a long time.

Method used

The execution parameters of the first query statement in the database are obtained through the script, the slow query statement is determined as the second query statement, and the problem content is determined according to its statement structure, and marked and displayed in the display interface.

Benefits of technology

Fast positioning of problem content in slow query statements improves problem positioning efficiency and reduces the workload and time of operation and maintenance personnel.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119415553A_ABST
    Figure CN119415553A_ABST
Patent Text Reader

Abstract

The invention discloses a data verification method and device, equipment, a storage medium and a program product, and is applied to the field of data processing.The method comprises the steps that execution parameters of all first query statements collected by a script in a database are obtained; according to the execution parameters, a slow query statement is determined in all the first query statements to serve as a second query statement, and the slow query statement is used for indicating the first query statement with the execution duration larger than the first preset duration; according to the statement structure of the second query statement, question content in the second query statement is determined, and the question content is content causing the second query statement to become a slow query statement; marking the question content in the second query statement, and displaying the marked second query statement in a display interface associated with the script. According to the method, the problem positioning efficiency of the slow query statement is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the field of data processing technology, and in particular, relates to a data verification method, device, equipment, storage medium and program product. Background Art

[0002] A large amount of data is stored in the database, and users can query the data in the database.

[0003] The data in the database can be queried through query statements, and the query statements that take a long time to execute in the database are slow query statements. In order to improve the efficiency of data query, it is necessary to locate the problem of slow query statements and optimize the slow query statements to improve the query efficiency of the optimized query statements.

[0004] In the exemplary technology, the operation and maintenance personnel locate the problem of the slow query statement, but the slow query statement has a lot of related content, and the operation and maintenance personnel need to view all the related content of the slow query statement, which results in a long time to locate the problem of the slow query statement, and there is a problem of low efficiency in locating the problem of the slow query statement. Summary of the invention

[0005] The embodiments of the present application provide a data verification method, apparatus, device, storage medium, and program product for solving the problem of low efficiency in locating problems of slow query statements.

[0006] In a first aspect, an embodiment of the present application provides a data verification method, comprising:

[0007] Obtaining execution parameters of each first query statement collected by the script in the database;

[0008] According to the execution parameter, a slow query statement is determined in each of the first query statements as a second query statement, wherein the slow query statement is used to indicate a first query statement whose execution time is longer than a first preset time;

[0009] Determining problematic content in the second query statement according to the statement structure of the second query statement, where the problematic content is content that causes the second query statement to become a slow query statement;

[0010] The question content in the second query statement is marked, and the marked second query statement is displayed in a display interface associated with the script.

[0011] In one embodiment, the execution parameters include the execution duration and the execution end time point of the first query statement, and the step of displaying the marked second query statement in the display interface associated with the script includes:

[0012] Determining the execution start time of the second query statement according to the execution end time of the second query statement and the execution duration;

[0013] Sort the third query statements based on the order of the execution start time points from early to late, the third query statements being used to indicate the marked second query statements;

[0014] In the display interface associated with the script, the sorted third query statements are displayed.

[0015] In another embodiment, the step of displaying the marked second query statement in the display interface associated with the script includes:

[0016] Based on the identifier of the second query statement, sending a data acquisition request to the database, wherein the data acquisition request is used to request to acquire query result information of the second query statement;

[0017] Receiving response information and a first data entity sent by the database;

[0018] In response to the response information, determining that the target number of rows of the query result information is less than or equal to a preset number of rows, taking the first data entity as the query result information;

[0019] The marked second query statement and corresponding query result information are displayed in a display interface associated with the script.

[0020] In another embodiment, after the step of receiving the response information sent by the database, the method further includes:

[0021] In response to the response information, determining that the target number of rows of the query result information is greater than a preset number of rows, receiving a second data entity sent by the database;

[0022] The first data entity and the second data entity are concatenated to obtain query result information of the second query statement.

[0023] In another embodiment, the step of sending a data acquisition request to the database based on the identifier of the second query statement includes:

[0024] Displaying a first login interface of the database;

[0025] In response to a first login operation on the first login interface, acquiring database account information of the database based on the first login operation;

[0026] In response to the database account information passing verification, a data acquisition request is sent to the database based on the account corresponding to the data account information.

[0027] In another embodiment, the execution parameter includes the execution time of the first query statement, and the step of determining a slow query statement as the second query statement in each of the first query statements according to the execution parameter includes:

[0028] According to the execution time, determining a fourth query statement in each of the first query statements, wherein the execution time of the fourth query statement is greater than the first preset time;

[0029] In each of the fourth query statements, a second query statement is determined, the execution time of the second query statement is less than a second preset time, and the second preset time is greater than the first execution time.

[0030] In another embodiment, the step of determining the fourth query statement in each of the first query statements according to the execution time includes:

[0031] Verifying the execution parameters of the first query statement;

[0032] Deleting the first query statement corresponding to the execution parameter that failed the verification;

[0033] Based on the execution parameters of the remaining first query statements, a fourth query statement is determined from the remaining first query statements.

[0034] In another embodiment, the step of obtaining execution parameters of each first query statement collected by the script in the database includes:

[0035] Displaying a second login interface of the application associated with the script;

[0036] In response to detecting a second login operation on the second login interface, obtaining script account information corresponding to the second login operation;

[0037] In response to the script account information passing the verification, displaying a display interface of the application program;

[0038] Based on the display interface of the application, the execution parameters of each first query statement collected by the script in the database are obtained, and the display interface of the application is the display interface associated with the script.

[0039] In a second aspect, an embodiment of the present application provides a data verification device, including:

[0040] An acquisition module, used to acquire execution parameters of each first query statement collected by the script in the database;

[0041] A first determining module, configured to determine, according to the execution parameter, a slow query statement in each of the first query statements as a second query statement, wherein the slow query statement is used to indicate a first query statement whose execution time is longer than a first preset time;

[0042] A second determining module is used to determine problematic content in the second query statement according to the statement structure of the second query statement, where the problematic content is content that causes the second query statement to become a slow query statement;

[0043] A marking module is used to mark the question content in the second query statement and display the marked second query statement in a display interface associated with the script.

[0044] In a third aspect, an embodiment of the present application provides a data verification device, comprising: a processor and a memory storing computer program instructions; when the processor executes the computer program instructions, the data verification method as described above is implemented.

[0045] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, characterized in that computer program instructions are stored on the computer-readable storage medium, and when the computer program instructions are executed by a processor, the data verification method as described above is implemented.

[0046] In a fifth aspect, an embodiment of the present application provides a computer program product. When instructions in the computer program product are executed by a processor of an electronic device, the electronic device is enabled to perform the data verification method as described above.

[0047] The data verification method, apparatus, device, storage medium and program product of the embodiments of the present application obtain the execution parameters of the first query statement in the database through a script, determine the slow query statement as the second query statement in each first query statement based on the execution parameters, determine the problem content in the second query statement according to the statement structure of the second query statement, mark the problem content in the second query statement, and then display the marked query statement in the display interface associated with the script. In the present application, the execution parameters of the first query statement collected by the script are used to quickly determine the problem content in the second query statement as the slow query statement, and mark the problem content in the second query statement, so that the operation and maintenance personnel can quickly locate the problem of the slow query statement based on the marked problem content, thereby improving the efficiency of locating problems with the slow query statement. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] In order to more clearly illustrate the technical solution of the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0049] Figure 1 It is a schematic diagram of the scenario involved in the data verification method of this application;

[0050] Figure 2 It is a flowchart of the first embodiment of the data verification method of the present application;

[0051] Figure 3 It is a flow chart of the second embodiment of the data verification method of the present application;

[0052] Figure 4 It is a flowchart of the third embodiment of the data verification method of the present application;

[0053] Figure 5 It is a flowchart of the fourth embodiment of the data verification method of the present application;

[0054] Figure 6 It is a flowchart of the fifth embodiment of the data verification method of the present application;

[0055] Figure 7 It is a functional module schematic diagram of the data verification device of the present application;

[0056] Figure 8 It is a structural diagram of the data verification equipment of this application. DETAILED DESCRIPTION

[0057] The features and exemplary embodiments of various aspects of the present application will be described in detail below. In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only intended to explain the present application, rather than to limit the present application. For those skilled in the art, the present application can be implemented without the need for some of these specific details. The following description of the embodiments is only to provide a better understanding of the present application by illustrating the examples of the present application.

[0058] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the statement "include..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.

[0059] It should be noted that the acquisition, storage, use and processing of data in the embodiments of the present application are in compliance with the relevant provisions of national laws and regulations.

[0060] It should be noted that in the embodiments of the present application, certain software, components, models and other existing solutions in the industry may be mentioned, and they should be regarded as exemplary. Their purpose is only to illustrate the feasibility of implementing the technical solution of the present application, but it does not mean that the applicant has or will necessarily use the solution.

[0061] A large amount of data is stored in the database, and users can query the data in the database.

[0062] The data in the database can be queried through query statements, and the query statements that take a long time to execute in the database are slow query statements. In order to improve the efficiency of data query, it is necessary to locate the problem of slow query statements and optimize the slow query statements to improve the query efficiency of the optimized query statements.

[0063] The inventor of the present application discovered that the problem of slow query statements is located by operation and maintenance personnel, but the slow query statements have a lot of related content, and the operation and maintenance personnel need to view all the related content of the slow query statements, which results in a long time for locating the problem of the slow query statements and a low efficiency in locating the problem of the slow query statements.

[0064] The inventor of the present application therefore came up with the idea of ​​quickly determining the problem content in the second query statement, which is a slow query statement, through the execution parameters of the first query statement collected by the script, and marking the problem content in the second query statement, so that operation and maintenance personnel can quickly locate the problem in the slow query statement based on the marked problem content, thereby improving the efficiency of locating problems in the slow query statement.

[0065] Reference Figure 1 , Figure 1 This is a schematic diagram of the scenario of the data verification method of this application. Figure 1 , the data verification device 100 is in communication connection with the database 200. The database 200 is provided with a script, and the script can monitor the execution parameters of the database 200 executing the first query statement. The data verification device 100 obtains the execution parameters of each first query statement based on the script, and determines the slow query statement as the second query statement in each first query statement based on the execution parameters. The data verification device 100 determines the problem content in the second query statement based on the execution parameters of the second query statement, and then marks the problem content in the second query statement, and displays the marked second query statement in the display interface 110 associated with the script, for example, the marked content is Figure 1 Medium bold black characters.

[0066] The following combination Figure 1 , the data verification method of this application is described in detail.

[0067] Reference Figure 2 , Figure 2 FIG. 1 is a flow chart of a first embodiment of a data verification method of the present application. The data verification method includes:

[0068] Step S201, obtaining execution parameters of each first query statement collected by the script in the database.

[0069] In this embodiment, the execution subject is a data verification device. For the convenience of description, the device is used below to refer to the data verification device. The device can be a mobile phone, a computer, or a server or virtual device with a data verification function.

[0070] A script is set in the database, and the script is used to monitor the query statements executed in the database and generate execution parameters of the executed query statements, and the execution parameters include parameters such as the execution duration and end time point of the query statements. The execution parameters collected by the script and the first query statement corresponding to the execution parameters are associated and stored in the database. The query statement executed in the database is defined as the first query statement.

[0071] The device is loaded with an application associated with the script, such as a browser. By inputting the database IP, port, and time range in the browser, the device can obtain the execution parameters of the first query statement executed within the specified time range from the specified database.

[0072] Step S202: According to the execution parameters, a slow query statement is determined in each first query statement as the second query statement, where the slow query statement is used to indicate a first query statement whose execution time is longer than a first preset time.

[0073] After obtaining the execution parameters of each first query statement, the device determines a slow query statement as the second query statement in each first query statement based on the execution parameters. Exemplarily, the execution parameters include the execution time of the first query statement, and the device determines whether the execution time is greater than the first preset time. If the execution time is greater than the first preset time, the first query statement corresponding to the execution time is a slow query statement, and the slow query statement is used as the second query statement. It can be understood that the slow query statement is used to indicate the first query statement whose execution time is greater than the first preset time.

[0074] Step S203: determining problematic content in the second query statement according to the statement structure of the second query statement, where the problematic content is content that causes the second query statement to become a slow query statement.

[0075] After determining the second query statement, the device determines problematic content in the second query statement based on the statement structure of the second query statement, where the problematic content is content that causes the second query statement to become a slow query statement.

[0076] In one example, the device parses the second query statement to obtain the statement structure of the second query statement, where the statement structure includes sub-queries of the second query statement, and determines whether there are sub-queries with the same query results based on each sub-query. If there are sub-queries with the same query results, the sub-query is the question content.

[0077] In another example, if the syntax in the second query statement is not set correctly, the subquery may be executed repeatedly multiple times. The device obtains the field representing the execution condition in the second query statement based on the statement structure. If the field causes the corresponding subquery to be executed repeatedly multiple times, then the field is the problem content.

[0078] In another example, the second query statement of the device is input into the recognition model, and the recognition model outputs the problematic content in the second query statement, that is, the problematic content in the second query statement output by the recognition model is obtained. The recognition model is obtained through training samples, and the training samples include training query statements, some training query statements include slow query statements, problematic content in the slow query statements, and labels, and the labels are used to indicate that the training query statements in the training samples are slow query statements; some training query statements are non-slow query statements and labels, and the labels are used to execute that the query statements in the training samples are not slow query statements; the recognition model can be obtained by training the preset model through each training sample.

[0079] Step S204: mark the question content in the second query statement, and display the marked second query statement in a display interface associated with the script.

[0080] After determining the problematic content in the second query statement, the problematic content in the second query statement is marked, and the marking method can be to highlight and mark the problematic content in red in the second query statement. The device then displays the marked second query statement in the display interface associated with the script. The display interface associated with the script is the interface of the browser associated with the script, that is, the problematic content of the second query statement is visually displayed in the display interface, which is convenient for operation and maintenance personnel to locate the problem of the query statement, thereby optimizing the slow query statement and ensuring that the operation of the database is in a healthy state.

[0081] In this embodiment, the execution parameters of the first query statement in the database are obtained through a script, and a slow query statement is determined as the second query statement in each first query statement based on the execution parameters, and the problem content in the second query statement is determined according to the statement structure of the second query statement, and the problem content in the second query statement is marked, and then the marked query statement is displayed in the display interface associated with the script. In this embodiment, the execution parameters of the first query statement collected by the script are used to quickly determine the problem content in the second query statement as the slow query statement, and the problem content in the second query statement is marked, so that the operation and maintenance personnel can quickly locate the problem of the slow query statement based on the marked problem content, thereby improving the efficiency of locating problems with the slow query statement.

[0082] Reference Figure 3 , Figure 3 This is a flow chart of the second embodiment of the data verification method of the present application. Based on the first embodiment, step S204 includes:

[0083] Step S301, determining the execution start time of the second query statement according to the execution end time and execution duration of the second query statement.

[0084] In this embodiment, the execution parameters include the execution duration and the execution end time of the first query statement. The device determines the execution start time of the second query statement based on the execution end time and the execution duration of the second query statement. Exemplarily, the execution start time can be obtained by pushing the execution end time forward by the execution duration.

[0085] Step S302: sort the third query statements based on the order of the execution start time points from early to late, where the third query statements are used to indicate the marked second query statements.

[0086] After obtaining the execution start time points of each second query statement, the device sorts each third query statement in order of execution time points from early to late, the third query statement is the marked second query statement, and the head of each sorted third query statement is the execution start time point.

[0087] Step S303: display the sorted third query statements in a display interface associated with the script.

[0088] After obtaining the sorted third query statements, the device displays the sorted third query statements in a display interface associated with the script.

[0089] In this embodiment, since each sorted third query statement has an execution start time point, the operation and maintenance personnel can locate the target time point for starting to execute the slow query statement in the database based on each sorted third query statement, and the source of the slow query statement in the database can be determined based on the target time point, that is, the source of the slow query statement can be located based on each sorted third query statement.

[0090] Reference Figure 4 , Figure 4 This is a flow chart of the third embodiment of the data verification method of the present application. Based on the first or second embodiment, step S204 includes:

[0091] Step S401: Based on the identifier of the second query statement, a data acquisition request is sent to the database, where the data acquisition request is used to request to acquire query result information of the second query statement.

[0092] In this embodiment, the device can display the query details of the second query statement while displaying the question content of the marked second query statement, and the query details are the query result information of the second query statement. The query result information is stored in a database, and the device needs to obtain the query result information of the second query statement from the database.

[0093] After determining the second query statement, the device sends a data acquisition request to the database based on the identifier of the second query statement, that is, generates a data acquisition request based on the identifier of the second query statement. The data acquisition request is used to request to obtain the query result information of the second query statement.

[0094] After receiving the data acquisition request, the database parses the data acquisition request to obtain an identifier, and then obtains the query result information associated with the identifier. In order to reduce the data transmission of the database, the amount of data sent by the database cannot exceed the preset threshold. For example, the database only sends less than 3,000 rows of data each time. After obtaining the query result information, the database determines the number of rows of the query result information, which is defined as the target number of rows, and generates response information based on the target number of rows, and obtains the data entity based on the query result information. The data entity is defined as the first data entity, and the number of rows of the first data entity is less than the preset number of rows.

[0095] Step S402: receiving response information and a first data entity sent by the database.

[0096] Step S403: In response to the response information, it is determined that the target number of rows of the query result information is less than or equal to the preset number of rows, and the first data entity is used as the query result information.

[0097] The device receives the response information and the first data entity sent by the database, obtains the target number of rows of the query result information from the response information, and compares the target number of rows with the preset number of rows.

[0098] When the target number of rows is less than or equal to the preset number of rows, it can be determined that the number of rows of the first data entity is the target number of rows, that is, the first data entity is the query result information, and the first data entity is used as the query result information.

[0099] When the target number of rows is greater than the preset number of rows, the number of rows of the first data entity is the preset number of rows, and the device continues to receive data entities, and defines the data entity to be received as a second data entity, and the second data entity is at least one. The device splices the first data entity and the second data entity to obtain the query result information of the second query statement, and the sum of the number of rows of the first data entity and the second data entity is the target number of rows.

[0100] Further, when it is necessary to obtain the query result information from the database, an account that logs into the database is required. After the account that logs into the database is registered, it can be determined that the account is registered in the database, and the database can authorize the account to obtain data. In this regard, the device displays the first login interface of the database, and the user can perform a login operation on the first login interface; when the device detects the first login operation on the first login interface, it obtains the database account information of the database based on the first login operation, that is, it obtains the input database account and database password based on the first login operation, and sends the database account information to the database for verification. If the database determines that the database account and database password in the data account information are correct, it can be determined that the database account information has passed the verification, and the device can send a data acquisition request to the database based on the account corresponding to the database account information to obtain the query result information. Exemplarily, if the database passes the verification of the database account information, the device displays the operation interface of the database, and the identifier of the second query statement is entered in the operation interface to generate a data acquisition request, and then the account and the data acquisition request are sent to the database. The database returns the response information and the first data entity.

[0101] Step S404: display the marked second query statement and corresponding query result information in a display interface associated with the script.

[0102] After obtaining the query result information, the device displays the marked second query statement and the corresponding query result information in the display interface associated with the script.

[0103] In this embodiment, the device displays the marked second query statement and the corresponding query result information in the display interface, so that the operation and maintenance personnel can view the query details in the second query statement and the problem content in the second query statement, thereby facilitating the operation and maintenance personnel to quickly locate the problems with the slow query statement.

[0104] Reference Figure 5 , Figure 5This is a flow chart of a fourth embodiment of the data verification method of the present application, based on any one of the first to third embodiments, step S202 includes:

[0105] Step S501: Determine a fourth query statement in each first query statement according to the execution time, wherein the execution time of the fourth query statement is greater than the first preset time.

[0106] In this embodiment, the execution parameters include execution time. The device determines the fourth query statement in each first query statement based on the execution time. The execution time of the fourth query statement is greater than the first preset time. The first query statement corresponding to the execution time greater than the first preset time is determined as the fourth query statement.

[0107] Furthermore, after obtaining the execution parameters of the first query statement collected by the script, the device verifies the execution parameters of the first query statement. The verification content includes, for example, whether there are missing parameters in the execution parameters, whether there are parameter name errors, and whether the parameter values ​​are abnormal. If there are no missing parameters, no parameter name errors, and the parameter values ​​are normal values, the verification passes; if there are missing parameters, parameter name errors, and / or the parameter values ​​are abnormal values, the verification fails. The device deletes the first query statement corresponding to the execution parameters that have not passed the verification, and then determines the fourth query statement from the remaining first query statements based on the execution parameters of the remaining first query statements, that is, if the execution time of the first query statement that passes the verification is greater than the first time, then the first query statement that passes the verification is determined to be the fourth query statement.

[0108] Step S502: in each fourth query statement, determine a second query statement, the execution time of the second query statement is less than the second preset time, and the second preset time is greater than the first execution time.

[0109] If the device uses a slow query statement with an excessively long execution time, it will take a long time to locate the problem, and it will affect the accuracy of the problem location. Therefore, it is not appropriate to use the fourth query statement with an excessively long execution time. In this regard, the device compares the execution time of the fourth execution time with the second preset time, the second preset time is greater than the first preset time, and the second preset time is, for example, 1 hour.

[0110] When the execution time of the fourth query statement is less than the second preset time, the fourth query statement is determined as the second query statement to locate the problem.

[0111] In this embodiment, the device uses the fourth query statement with a shorter execution time to locate the problem of the slow query statement, ensuring that the location time of the slow query statement is not too long, thereby ensuring the efficiency of locating the problem of the slow query statement.

[0112] Reference Figure 6, Figure 6 This is a flowchart of the fifth embodiment of the data verification method of the present application, based on any one of the first to fourth embodiments, step S201 includes:

[0113] Step S601: displaying a second login interface of an application program associated with the script.

[0114] In this embodiment, the device is loaded with an application program associated with the script, such as a browser, and the user needs to log in to the application program to obtain the parameters collected by the script.

[0115] In response, the device displays a second login interface of the application associated with the script.

[0116] Step S602, in response to detecting a second login operation on a second login interface, obtaining script account information corresponding to the second login operation.

[0117] Step S603, in response to the script account information passing the verification, displaying the display interface of the application.

[0118] The user can perform a login operation on the second login interface, and the login operation is defined as the second login operation. The second login operation is, for example, inputting an account and password on the second login interface. When the device detects the second login operation on the second login interface, it obtains the script account information corresponding to the second login operation. The device sends the script account information to the background of the application for verification. If the script account and password in the script account information are correct, the script account information passes the verification, and the background feeds back the display interface of the application to the device, so that the device can obtain the execution parameters collected by the script based on the display interface, that is, the device displays the received display interface.

[0119] Step S604, based on the display interface of the application program, obtaining the execution parameters of each first query statement collected by the script in the database, the display interface of the application program being the display interface associated with the script.

[0120] The user can enter the database ID, port and time range on the display interface. The background of the application locates the script in the database based on the database ID and port. The background displays the execution parameters collected by the script in the database within the time range on the display interface, so that the device obtains the execution parameters of each first query statement from the display interface.

[0121] In this embodiment, the device can quickly obtain the execution parameters collected by the script from the database by logging into the application associated with the script, thereby improving the efficiency of locating problems of slow query statements.

[0122] See also Figure 7, the data verification device 700 provided in the embodiment of the present application, the data verification device 700 includes:

[0123] An acquisition module 710 is used to acquire execution parameters of each first query statement collected by the script in the database;

[0124] A first determining module 720 is used to determine, according to the execution parameter, a slow query statement in each first query statement as a second query statement, where the slow query statement is used to indicate a first query statement whose execution time is longer than a first preset time;

[0125] A second determination module 730 is used to determine problematic content in the second query statement according to the statement structure of the second query statement, where the problematic content is content that causes the second query statement to become a slow query statement;

[0126] The marking module 740 is used to mark the question content in the second query statement and display the marked second query statement in the display interface associated with the script.

[0127] In one embodiment, the data verification device 700 is specifically used for:

[0128] Determine the execution start time of the second query statement according to the execution end time and execution duration of the second query statement;

[0129] Sort the third query statements based on the order of the execution start time points from early to late, the third query statements are used to indicate the marked second query statements;

[0130] In the display interface associated with the script, the sorted third query statements are displayed.

[0131] In one embodiment, the data verification device 700 is specifically used for:

[0132] Based on the identifier of the second query statement, a data acquisition request is sent to the database, where the data acquisition request is used to request to obtain query result information of the second query statement;

[0133] Receiving response information and the first data entity sent by the database;

[0134] In response to the response information, determining that the target number of rows of the query result information is less than or equal to the preset number of rows, taking the first data entity as the query result information;

[0135] The marked second query statement and corresponding query result information are displayed in a display interface associated with the script.

[0136] In one embodiment, the data verification device 700 is specifically used for:

[0137] In response to the response information, determining that the target number of rows of the query result information is greater than the preset number of rows, receiving a second data entity sent by the database;

[0138] The first data entity and the second data entity are concatenated to obtain query result information of the second query statement.

[0139] In one embodiment, the data verification device 700 is specifically used for:

[0140] Display the first login interface of the database;

[0141] In response to a first login operation on the first login interface, obtaining database account information of the database based on the first login operation;

[0142] In response to the database account information passing verification, a data acquisition request is sent to the database based on the account corresponding to the data account information.

[0143] In one embodiment, the data verification device 700 is specifically used for:

[0144] According to the execution time, a fourth query statement is determined in each first query statement, and the execution time of the fourth query statement is greater than the first preset time;

[0145] In each fourth query statement, a second query statement is determined, the execution time of the second query statement is less than the second preset time, and the second preset time is greater than the first execution time.

[0146] In one embodiment, the data verification device 700 is specifically used for:

[0147] Verifying the execution parameters of the first query statement;

[0148] Deleting the first query statement corresponding to the execution parameter that failed the verification;

[0149] Based on the execution parameters of the remaining first query statements, a fourth query statement is determined from the remaining first query statements.

[0150] In one embodiment, the data verification device 700 is specifically used for:

[0151] Display a second login interface of the application associated with the script;

[0152] In response to detecting a second login operation on the second login interface, obtaining script account information corresponding to the second login operation;

[0153] In response to the script account information passing verification, displaying a display interface of the application;

[0154] Based on the display interface of the application program, the execution parameters of each first query statement collected by the script in the database are obtained, and the display interface of the application program is the display interface associated with the script.

[0155] Each module of the data verification device provided in the embodiment of the present application can realize Figures 2 to 6 Any embodiment provides the functions of each step of the data verification method and can achieve its corresponding technical effects. For the sake of concise description, they will not be repeated here.

[0156] Figure 8 A schematic diagram of the hardware structure of a data verification device provided in an embodiment of the present application is shown.

[0157] The data verification device may include a processor 801 and a memory 802 storing computer program instructions.

[0158] Specifically, the processor 801 may include a central processing unit (CPU), or an application specific integrated circuit (ASIC), or may be configured to implement one or more integrated circuits of the embodiments of the present application.

[0159] The memory 802 may include a large capacity memory for data or instructions. By way of example and not limitation, the memory 802 may include a hard disk drive (HDD), a floppy disk drive, a flash memory, an optical disk, a magneto-optical disk, a magnetic tape, or a universal serial bus (USB) drive or a combination of two or more of these. In appropriate cases, the memory 802 may include a removable or non-removable (or fixed) medium. In appropriate cases, the memory 802 may be inside or outside the integrated gateway disaster recovery device. In a specific embodiment, the memory 802 is a non-volatile solid-state memory.

[0160] In certain embodiments, the memory 802 may include a read-only memory (ROM), a random access memory (RAM), a magnetic disk storage media device, an optical storage media device, a flash memory device, an electrical, optical or other physical / tangible memory storage device. Thus, in general, the memory includes one or more tangible (non-transitory) computer-readable storage media (e.g., a memory device) encoded with software including computer-executable instructions, and when the software is executed (e.g., by one or more processors), it is operable to perform the operations described with reference to the method according to an aspect of the present disclosure.

[0161] The processor 801 implements any one of the authentication methods in the above embodiments by reading and executing computer program instructions stored in the memory 802 .

[0162] In one example, the data verification device may further include a communication interface 803 and a bus 810. Figure 8 As shown, the processor 801, the memory 802, and the communication interface 803 are connected via a bus 810 and communicate with each other.

[0163] The communication interface 803 is mainly used to implement communication between various modules, devices, units and / or equipment in the embodiments of the present application.

[0164] Bus 810 includes hardware, software or both, and the parts of online data flow billing equipment are coupled to each other. For example, but not limitation, bus may include accelerated graphics port (AGP) or other graphics bus, enhanced industrial standard architecture (EISA) bus, front-end bus (FSB), hypertransport (HT) interconnection, industrial standard architecture (ISA) bus, infinite bandwidth interconnection, low pin count (LPC) bus, memory bus, micro channel architecture (MCA) bus, peripheral component interconnection (PCI) bus, PCI-Express (PCI-X) bus, serial advanced technology attachment (SATA) bus, video electronics standard association local (VLB) bus or other suitable bus or two or more of these combinations. In appropriate cases, bus 810 may include one or more buses. Although the present application embodiment describes and shows a specific bus, the application considers any suitable bus or interconnection.

[0165] The data verification method in the above embodiment can be implemented by providing a computer storage medium in the present application embodiment. The computer storage medium stores computer program instructions; when the computer program instructions are executed by a processor, any one of the data verification methods in the above embodiment is implemented.

[0166] An embodiment of the present application also provides a computer program product, including a computer program, which implements any one of the data verification methods in the above embodiments when the computer program is processed and executed.

[0167] It should also be noted that the exemplary embodiments mentioned in this application describe some methods or systems based on a series of steps or devices. However, this application is not limited to the order of the above steps, that is, the steps can be performed in the order mentioned in the embodiment, or in a different order from the embodiment, or several steps can be performed simultaneously.

[0168] Aspects of the present disclosure are described above with reference to the flowchart and / or block diagram of the method, device (system) and computer program product according to the embodiment of the present disclosure. It should be understood that each square block in the flowchart and / or block diagram and the combination of each square block in the flowchart and / or block diagram can be realized by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer or other programmable data verification device to produce a machine so that these instructions executed via the processor of the computer or other programmable data verification device enable the realization of the function / action specified in one or more square blocks of the flowchart and / or block diagram. This processor can be, but is not limited to, a general-purpose processor, a special-purpose processor, a special application processor or a field programmable logic circuit. It can also be understood that each square block in the block diagram and / or flowchart and the combination of the square blocks in the block diagram and / or flowchart can also be realized by the dedicated hardware that performs the specified function or action, or can be realized by the combination of dedicated hardware and computer instructions.

[0169] The above are only specific implementation methods of the present application. Those skilled in the art can clearly understand that for the convenience and simplicity of description, the specific working processes of the systems, modules and units described above can refer to the corresponding processes in the aforementioned method embodiments, and will not be repeated here. It should be understood that the protection scope of the present application is not limited to this. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed in this application, and these modifications or replacements should be included in the protection scope of this application.

Claims

1. A data verification method, characterized in that: include: Obtaining execution parameters of each first query statement collected by the script in the database; According to the execution parameter, a slow query statement is determined in each of the first query statements as a second query statement, wherein the slow query statement is used to indicate a first query statement whose execution time is longer than a first preset time; Determining problematic content in the second query statement according to the statement structure of the second query statement, where the problematic content is content that causes the second query statement to become a slow query statement; The question content in the second query statement is marked, and the marked second query statement is displayed in a display interface associated with the script.

2. The data verification method according to claim 1, characterized in that: The execution parameters include the execution duration and the execution end time of the first query statement, and the step of displaying the marked second query statement in the display interface associated with the script includes: Determining a start time point for executing the second query statement according to the end time point for executing the second query statement and the execution duration; Sort the third query statements based on the order of the execution start time points from early to late, the third query statements being used to indicate the marked second query statements; In the display interface associated with the script, the sorted third query statements are displayed.

3. The data verification method according to claim 1, characterized in that: The step of displaying the marked second query statement in the display interface associated with the script includes: Based on the identifier of the second query statement, sending a data acquisition request to the database, wherein the data acquisition request is used to request to acquire query result information of the second query statement; Receiving response information and a first data entity sent by the database; In response to the response information, determining that the target number of rows of the query result information is less than or equal to a preset number of rows, taking the first data entity as the query result information; The marked second query statement and corresponding query result information are displayed in a display interface associated with the script.

4. The data verification method according to claim 3, characterized in that: After the step of receiving the response information sent by the database, the method further includes: In response to the response information, determining that the target number of rows of the query result information is greater than a preset number of rows, receiving a second data entity sent by the database; The first data entity and the second data entity are concatenated to obtain query result information of the second query statement.

5. The data verification method according to claim 3, characterized in that: The step of sending a data acquisition request to the database based on the identifier of the second query statement includes: Displaying a first login interface of the database; In response to a first login operation on the first login interface, acquiring database account information of the database based on the first login operation; In response to the database account information passing verification, a data acquisition request is sent to the database based on the account corresponding to the data account information.

6. The data verification method according to claim 1, characterized in that: The execution parameter includes the execution time of the first query statement, and the step of determining a slow query statement as the second query statement in each of the first query statements according to the execution parameter includes: According to the execution time, determining a fourth query statement in each of the first query statements, wherein the execution time of the fourth query statement is greater than the first preset time; In each of the fourth query statements, a second query statement is determined, the execution time of the second query statement is less than a second preset time, and the second preset time is greater than the first execution time.

7. The data verification method according to claim 6, characterized in that: The step of determining the fourth query statement in each of the first query statements according to the execution time includes: Verifying the execution parameters of the first query statement; Deleting the first query statement corresponding to the execution parameter that failed the verification; Based on the execution parameters of the remaining first query statements, a fourth query statement is determined from the remaining first query statements.

8. The data verification method according to claim 1, characterized in that: The step of obtaining the execution parameters of each first query statement collected by the script in the database includes: Displaying a second login interface of the application associated with the script; In response to detecting a second login operation on the second login interface, obtaining script account information corresponding to the second login operation; In response to the script account information passing the verification, displaying a display interface of the application program; Based on the display interface of the application, the execution parameters of each first query statement collected by the script in the database are obtained, and the display interface of the application is the display interface associated with the script.

9. A data verification device, characterized in that: include: An acquisition module, used to acquire execution parameters of each first query statement collected by the script in the database; A first determining module, configured to determine, according to the execution parameter, a slow query statement in each of the first query statements as a second query statement, wherein the slow query statement is used to indicate a first query statement whose execution time is longer than a first preset time; A second determining module is used to determine problematic content in the second query statement according to the statement structure of the second query statement, where the problematic content is content that causes the second query statement to become a slow query statement; A marking module is used to mark the question content in the second query statement and display the marked second query statement in a display interface associated with the script.

10. A data verification device, characterized in that: The device comprises: a processor and a memory storing computer program instructions; when the processor executes the computer program instructions, the data verification method according to any one of claims 1 to 8 is implemented.

11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer program instructions, and when the computer program instructions are executed by a processor, the data verification method according to any one of claims 1 to 8 is implemented.

12. A computer program product, characterized in that When the instructions in the computer program product are executed by a processor of an electronic device, the electronic device is enabled to execute the data verification method as described in any one of claims 1 to 8.