Multi-thread SQL (Structured Query Language) query and progress tracking method and system
Through multi-threading SQL queries and real-time progress tracking, the problems of inefficiency and progress agnosticity of traditional data queries are solved, and efficient and accurate data acquisition and error management are achieved.
Patent Information
- Application Number
- CN202411267097.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-11
- Publication Date
- 2024-12-31
AI Technical Summary
Traditional data query and report generation methods rely on manual operations by scientific and technological personnel, which are inefficient and prone to errors. Business personnel cannot understand the query progress in real time, which increases the time and error rate of data acquisition.
Multi-threaded SQL query and progress tracking methods are adopted to receive user requests through the web page, allocate multi-threaded SQL statements, update query progress in real time, and generate and download Excel files after the query is completed, providing query record tables for easy traceability.
It significantly improves query efficiency and data accuracy, reduces manual errors, provides real-time progress display and error information, facilitates rapid problem positioning, and reduces dependence on scientific and technological personnel.
Smart Images

Figure CN119226329A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a multi-thread SQL query and progress tracking method and system. Background Art
[0002] Structured Query Language (SQL) is a special-purpose programming language. It is a database query and programming language used to access data and query, update, and manage relational database systems. Structured Query Language is a high-level non-procedural programming language that allows users to work on high-level data structures. It does not require users to specify the storage method for data, nor does it require users to understand the specific data storage method. Therefore, different database systems with completely different underlying structures can use the same structured query language as an interface for data input and management. Structured query language statements can be nested, which makes it extremely flexible and powerful.
[0003] In the current information age, the management and analysis of enterprise data is crucial for business decision-making. However, traditional data query and report generation methods often rely on manual operations by scientific and technical personnel, which is not only inefficient but also prone to errors. Specifically, the existing technology has the following deficiencies:
[0004] 1) Currently, business personnel in many enterprises need to frequently make data query requests to scientific and technological personnel. Scientific and technological personnel write SQL query statements according to the requests, execute them in the database management system, and then return the results to business personnel. This manual data acquisition method is highly dependent on the intervention of scientific and technological personnel, which not only increases the workload of scientific and technological personnel, but also prolongs the time cycle for data acquisition and reduces work efficiency.
[0005] 2) During the manual data collection process, human factors (such as misunderstanding, operational errors, etc.) may cause the query results to not meet business specifications and require repeated proofreading and modification, which increases the complexity and error rate of data processing.
[0006] 3) The traditional batch query method is usually executed in the background. Business personnel cannot understand the query progress in real time, nor can they predict the time when the query will be completed, which increases the uncertainty of business decisions. When errors occur during the query process, due to the lack of an effective error tracking mechanism, scientific and technical personnel often need to spend a lot of time to troubleshoot and repair the problem, further extending the time for data acquisition. Summary of the invention
[0007] In view of this, it is necessary to provide a multi-threaded SQL query and progress tracking method to solve the above-mentioned defects of the prior art.
[0008] In order to solve the above problems, in a first aspect, an embodiment of the present invention provides a multi-threaded SQL query and progress tracking method, comprising:
[0009] The web page receives the user's query request, queries the SQL statement from the SQL configuration table, assembles the queried SQL statements into a SQL statement list, and calls the SQL multi-threaded query interface;
[0010] Call the SQL multi-threaded query interface and assign a thread to query each SQL statement in the SQL statement list;
[0011] After each thread query is completed, the query result is inserted into the query result record table, and the query progress of the user query record table is updated.
[0012] Preferably, receiving a user query request on a web page, querying SQL statements from an SQL configuration table, and assembling the queried SQL statements into an SQL statement list includes:
[0013] Receive a user query request on the web page, and record the user query request in a user query record table;
[0014] Call the SQL assembly interface, query SQL statements from the SQL configuration table according to the query options selected by the user, and assemble the queried SQL statements into a SQL statement list;
[0015] Update the status of the user query record table to querying.
[0016] Preferably, after calling the SQL multi-thread query interface and assigning a thread to query each SQL statement in the SQL statement list, the method further includes:
[0017] When all threads query successfully, the status of the query result record table is updated to success;
[0018] If any query thread fails, the status of the user query record table is updated to failure, and the error information is recorded in the user query record table, and the status of the user query record table is no longer updated to other states.
[0019] Preferably, when all thread queries are successful, the method further includes:
[0020] Call the Excel generation interface to generate an Excel file based on the data in the query result record table and save it on the server.
[0021] Update the address of the generated Excel file on the server to the corresponding field of the user query record table.
[0022] Preferably, it also includes:
[0023] The web page receives the Sql record query request, calls the Sql record query interface, and obtains the user query record from the user query record table.
[0024] Preferably, it also includes:
[0025] Call the Excel generation interface to generate an Excel file based on the data in the query result record table and save it on the server.
[0026] Update the address of the generated Excel file on the server to the corresponding field of the user query record table.
[0027] Preferably, after generating the Excel file according to the data in the query result record table, the method further includes:
[0028] The web page receives the Excel download request, calls the Excel download interface, and checks whether the record status of the user's query request is successful in the query result record table. If so, a JSON string containing the Excel file download link is generated and sent to the web page.
[0029] Preferably, during the query process, the SQL multi-threaded query interface reflects the query progress in real time by updating the process field of the user query record table;
[0030] Divide the query task into multiple threads. After each thread completes the query, increase the process value proportionally.
[0031] In a second aspect, an embodiment of the present invention provides a multi-threaded SQL query and progress tracking system, including a web page, a backend server, and a database:
[0032] The web page is used to receive user query requests and display query progress and query results;
[0033] The back-end server comprises:
[0034] User query interface, used to process user query requests, call SQL assembly interface to assemble SQL statement list, call SQL multi-thread query interface to start multi-thread query;
[0035] SQL assembly interface, used to query SQL statements from the SQL configuration table according to the query options selected by the user, and assemble the queried SQL statements into a SQL statement list;
[0036] SQL multi-threaded query interface, used to execute SQL queries in multiple threads, update query progress and query result record table;
[0037] SQL record query interface, used to obtain user query records from the user query record table according to the user name;
[0038] Excel generation interface, used to generate Excel files according to the data in the query result record table and update the file path of the user query record table;
[0039] Excel download interface, used to provide a download link for the Excel file;
[0040] The database includes:
[0041] The user query record table is used to store the query record information of each user query operation; wherein the query record information includes the query code searchId, the user name username, the query status status, the query progress process, the creation time create_time of the query request and the excel storage path;
[0042] sql configuration table, used to store executable SQL statements and their configuration information;
[0043] The query result record table is used to store the query results of each user query operation.
[0044] In a third aspect, the present invention further provides an electronic device, including a memory and a processor, wherein:
[0045] The memory is used to store programs;
[0046] The processor is coupled to the memory and is used to execute the program stored in the memory to implement the steps in the multi-threaded SQL query and progress tracking method as described in the embodiment of the first aspect of the present invention.
[0047] In a fourth aspect, the present invention further provides a computer-readable storage medium for storing computer-readable programs or instructions, which, when executed by a processor, can implement the steps in the multi-threaded SQL query and progress tracking method as described in the embodiment of the first aspect of the present invention.
[0048] Compared with the prior art, the multi-threaded SQL query and progress tracking method and system provided by the present invention have the following beneficial effects:
[0049] 1) The present invention can process a large number of SQL statements in parallel by introducing a multi-threaded query mechanism, thereby improving query efficiency. In a business scenario, when a large number of SQL statements up to 700 lines need to be processed, multi-threaded query can significantly reduce the overall query time, thereby improving the work efficiency of business personnel.
[0050] 2) The present invention provides a real-time query progress display function, so that users can intuitively see the query progress on the web page, avoiding the problem that users cannot know the query progress in the traditional query method. The present invention adds an error information display function, so that when an error occurs during the query process, the user can immediately obtain the error information, which is convenient for quickly locating the problem and handling it.
[0051] 3) The present invention reduces the need for manual data acquisition through automated query and report generation, reduces the possibility of human error, and improves the accuracy and standardization of data. Business personnel can directly obtain the required data through the web page without relying on the assistance of scientific and technological personnel, reducing the links of data transmission and proofreading.
[0052] 4) The present invention introduces a user query record table, which records the detailed information of each query, including user name, query time, query status, query results, etc. This provides traceability for user queries, facilitating subsequent data analysis and troubleshooting. The present invention provides a query record query interface, so that business personnel can view previous query records at any time, improving work efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] Figure 1 A flow chart of the multi-threaded SQL query and progress tracking method provided by the present invention;
[0054] Figure 2 This is a structural block diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION
[0055] The preferred embodiments of the present invention are described in detail below in conjunction with the accompanying drawings, wherein the accompanying drawings constitute a part of this application and are used together with the embodiments of the present invention to illustrate the principles of the present invention, but are not used to limit the scope of the present invention.
[0056] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0057] In the current information age, the management and analysis of enterprise data is crucial to business decision-making. However, traditional data query and report generation methods often rely on manual operations by technical personnel, which is not only inefficient but also prone to errors.
[0058] In view of this, the present invention provides a multi-threaded SQL query and progress tracking method, establishes a query function on the web page, allows business personnel to query the required data on the web page, and has a progress system that can display the query progress of multiple segments of data. After the query is completed, the excel synthesized by the query results can be downloaded on the query record page. The following will be explained and introduced through multiple embodiments.
[0059] Figure 1 The flowchart of the multi-thread SQL query and progress tracking method provided by the present invention is as follows. Figure 1 As shown, the multi-threaded SQL query and progress tracking method includes the following steps:
[0060] Step S1, the web page receives a user query request, queries SQL statements from an SQL configuration table, and assembles the queried SQL statements into an SQL statement list.
[0061] Specifically, the user initiates a query request on the front-end interface (i.e., the web page), the web page receives the user query request and sends it to the back-end server, and the user query interface of the back-end server records the user query request in a pre-created user query record table, with the initial status being "preparing".
[0062] Next, the user query interface calls the SQL assembly interface, queries SQL statements from the SQL configuration table according to the query options selected by the user, and assembles the queried SQL statements into a SQL statement list; the status of the user query record table is updated to querying.
[0063] Step S2, calling the SQL multi-thread query interface, and assigning a thread to query each SQL statement in the SQL statement list.
[0064] The present invention can process a large number of SQL statements in parallel by introducing a multi-threaded query mechanism, thereby improving query efficiency. In a business scenario, when a large number of SQL statements up to 700 lines need to be processed, multi-threaded query can significantly reduce the overall query time, thereby improving the work efficiency of business personnel.
[0065] Specifically, when all threads query successfully, the status of the query result record table is updated to success, and the Excel generation interface is called to generate an Excel file containing all query results, and the Excel file path in the user query record table is updated at the same time.
[0066] If any query thread fails, the status of the user query record table is updated to failure, and the error information is recorded in the user query record table, and the status of the user query record table is no longer updated to other states.
[0067] The embodiment of the present invention adds an error information display function. When an error occurs during the query process, the user can immediately obtain the error information, which is convenient for quickly locating the problem and handling it.
[0068] During the query process, the SQL multi-threaded query interface reflects the query progress in real time by updating the process field of the user query record table. Specifically, the query task is divided into multiple threads, and after each thread completes the query, the process value is increased proportionally.
[0069] Step S3: After each thread query is completed, the query result is inserted into the query result record table, and the query progress of the user query record table is updated.
[0070] The present invention reduces the need for manual data acquisition through automated query and report generation, reduces the possibility of human error, and improves the accuracy and standardization of data. Business personnel can directly obtain the required data through the web page without relying on the assistance of scientific and technological personnel, reducing the links of data transmission and proofreading.
[0071] The present invention provides a real-time query progress display function, and the user can intuitively see the query progress on the web page, avoiding the problem that the user cannot know the query progress in the traditional query method.
[0072] In a preferred embodiment of the present invention, the multi-threaded SQL query and progress tracking method provided by the present invention further includes:
[0073] The web page receives the Sql record query request, calls the Sql record query interface, and obtains the user query record from the user query record table.
[0074] Specifically, the business personnel request to query the previous query records through the front-end interface (web page), the web page receives the SQL record query request, and calls the SQL record query interface. The SQL record query interface obtains the user query record from the user query record table according to the user name (username).
[0075] The present invention provides a query record query interface, and business personnel can check previous query records at any time, thereby improving work efficiency.
[0076] In a preferred embodiment of the present invention, the multi-threaded SQL query and progress tracking method provided by the present invention further includes:
[0077] The web page receives the Excel download request, calls the Excel download interface, and checks whether the record status of the user's query request is successful in the query result record table. If so, a JSON string containing the Excel file download link is generated and sent to the web page.
[0078] Specifically, on the query record page on the web page, the user can click the Download Excel button for the query record with a status of "success" to initiate an Excel download request.
[0079] The web page receives the Excel download request and calls the Excel download interface. The Excel download interface of the back-end server checks whether the record status of the user's query request is successful in the query result record table. If so, the corresponding Excel file path is found according to the query code searchId, and the Excel file is returned to the web page as a response for the user to download.
[0080] In a preferred embodiment of the present invention, this embodiment provides a multi-threaded SQL query and progress tracking system, including a web page, a backend server and a database:
[0081] The web page is used to receive user query requests and display query progress and query results;
[0082] The back-end server includes a user query interface, an SQL assembly interface, an SQL multi-threaded query interface, an SQL record query interface, an Excel generation interface and an Excel download interface. Among them:
[0083] The user query interface is used to process user query requests, call the SQL assembly interface to assemble the SQL statement list, and call the SQL multi-threaded query interface to start multi-threaded query. In this embodiment, the user's query request is "query which business image pieces are missing", and the content of the user query interface is shown in Table 1. Figure 1 , the field name Sysdate_data refers to the time parameter option of the front-end user interface (web page). sqlProductList refers to the query option of the front-end user interface, sqlType is used to filter query records of a specific type, and username is the user id that initiated the query request.
[0084] Table 1
[0085]
[0086]
[0087] The SQL assembly interface is used to query SQL statements from the SQL configuration table according to the query options selected by the user, and assemble the queried SQL statements into a SQL statement list. The content of the SQL assembly interface is shown in Table 2.
[0088] Table 2
[0089]
[0090] The SQL multi-threaded query interface is used to execute SQL queries in multiple threads, assign a thread to query each SQL statement in the SQL statement list, and update the query progress and query result record table. The content of the SQL multi-threaded query interface is shown in Table 3. When all threads query successfully, the status of the query result record table is updated to success, and the Excel generation interface is called to generate an Excel file containing all query results, and the Excel file path in the user query record table is updated at the same time. If any query thread fails, the status of the user query record table is updated to failure, and the error information is recorded in the user query record table, and the status of the user query record table is no longer updated to other states.
[0091] Table 3
[0092]
[0093] The SQL record query interface is used to obtain user query records from the user query record table according to the user name. The content of the SQL record query interface is shown in Table 4. Specifically, the business personnel request to query the previous query records through the front-end interface (web page), and the web page receives the SQL record query request and calls the SQL record query interface. The SQL record query interface obtains the user query record from the user query record table according to the user name (username).
[0094] Table 4
[0095]
[0096] The Excel generation interface is used to generate an Excel file based on the data in the query result record table and update the file path of the user query record table. The content of the Excel generation interface is shown in Table 5. Specifically, when all threads query successfully, the status of the query result record table is updated to success, and the Excel generation interface is called to generate an Excel file containing all query results, and the Excel file path in the user query record table is updated at the same time.
[0097] Table 5
[0098]
[0099] The Excel download interface is used to provide a download link for the Excel file. The content of the Excel download interface is shown in Table 6. Specifically, in the query record page on the web page, for the query record with a status of "success", the user can click the Download Excel button to initiate an Excel download request. The web page receives the Excel download request and calls the Excel download interface. The Excel download interface of the back-end server checks whether the record status of the user's query request is successful in the query result record table. If so, the corresponding Excel file path is found according to the query code searchId, and the Excel file is returned to the web page as a response for the user to download.
[0100] Table 6
[0101]
[0102] In the multi-threaded SQL query and progress tracking system provided by the present invention, the database includes a user query record table, a SQL configuration table and a query result record table, wherein:
[0103] The user query record table is used to store the query record information of each user query operation; wherein the query record information includes the query code searchId, the user name username, the query status status, the query progress process, the creation time create_time of the query request and the excel storage path. The content of the user query record table is shown in Table 7.
[0104] Table 7
[0105]
[0106] The sql configuration table is used to store executable SQL statements and their configuration information. The contents of the sql configuration table are shown in Table 8.
[0107] Table 8
[0108]
[0109]
[0110] The query result record table is used to store the query result of each user query operation. The content of the query result record table is shown in Table 9.
[0111] Table 9
[0112]
[0113] The multi-threaded SQL query and progress tracking system provided by the present invention is used to execute the multi-threaded SQL query and progress tracking methods provided by the above embodiments. The multi-threaded SQL query and progress tracking methods have been described in detail in the above embodiments, and will not be repeated in this embodiment.
[0114] Figure 2 The structural block diagram of the electronic device provided by the present invention is as follows: Figure 2 As shown, the present invention also provides an electronic device, the electronic device 200 can be a computing device such as a mobile terminal, a desktop computer, a notebook, a palm computer, and a server. The electronic device 200 includes a processor 201 and a memory 202, wherein the memory 202 stores a multi-threaded SQL query and progress tracking program 203.
[0115] In some embodiments, the memory 202 may be an internal storage unit of a computer device, such as a hard disk or memory of the computer device. In other embodiments, the memory 202 may also be an external storage device of the computer device, such as a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), etc. equipped on the computer device. Furthermore, the memory 202 may also include both an internal storage unit of the computer device and an external storage device. The memory 202 is used to store application software and various types of data installed on the computer device, such as program codes installed on the computer device. The memory 202 may also be used to temporarily store data that has been output or is to be output. In one embodiment, when the multi-threaded SQL query and progress tracking program 203 is executed by the processor 201, the following steps are implemented:
[0116] The web page receives the user's query request, queries the SQL statement from the SQL configuration table, and assembles the queried SQL statements into a SQL statement list;
[0117] Call the SQL multi-threaded query interface and assign a thread to query each SQL statement in the SQL statement list;
[0118] After each thread query is completed, the query result is inserted into the query result record table, and the query progress of the user query record table is updated.
[0119] In some embodiments, the processor 201 may be a central processing unit (CPU), a microprocessor or other data processing chip, and is used to run program codes or process data stored in the memory 202, such as executing multi-threaded SQL queries and progress tracking programs.
[0120] This embodiment further provides a computer-readable storage medium on which a multi-threaded SQL query and progress tracking program is stored. When the multi-threaded SQL query and progress tracking program is executed by a processor, the following steps are implemented:
[0121] The web page receives the user's query request, queries the SQL statement from the SQL configuration table, and assembles the queried SQL statements into a SQL statement list;
[0122] Call the SQL multi-threaded query interface and assign a thread to query each SQL statement in the SQL statement list;
[0123] After each thread query is completed, the query result is inserted into the query result record table, and the query progress of the user query record table is updated.
[0124] In summary, the multi-threaded SQL query and progress tracking method and system provided by the present invention have the following beneficial effects compared with the prior art:
[0125] 1) The present invention can process a large number of SQL statements in parallel by introducing a multi-threaded query mechanism, thereby improving query efficiency. In a business scenario, when a large number of SQL statements up to 700 lines need to be processed, multi-threaded query can significantly reduce the overall query time, thereby improving the work efficiency of business personnel.
[0126] 2) The present invention provides a real-time query progress display function, so that users can intuitively see the query progress on the web page, avoiding the problem that users cannot know the query progress in the traditional query method. The present invention adds an error information display function, so that when an error occurs during the query process, the user can immediately obtain the error information, which is convenient for quickly locating the problem and handling it.
[0127] 3) The present invention reduces the need for manual data acquisition through automated query and report generation, reduces the possibility of human error, and improves the accuracy and standardization of data. Business personnel can directly obtain the required data through the web page without relying on the assistance of scientific and technological personnel, reducing the links of data transmission and proofreading.
[0128] 4) The present invention introduces a user query record table, which records the detailed information of each query, including user name, query time, query status, query results, etc. This provides traceability for user queries, facilitating subsequent data analysis and troubleshooting. The present invention provides a query record query interface, so that business personnel can view previous query records at any time, improving work efficiency.
[0129] The above-described embodiments only express several implementation methods of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the scope of the present invention. It should be pointed out that, for a person of ordinary skill in the art, several modifications and improvements can be made without departing from the concept of the present invention, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the attached claims.
[0130] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A multi-threaded SQL query and progress tracking method, characterized in that: include: The web page receives the user's query request, queries the SQL statement from the SQL configuration table, and assembles the queried SQL statements into a SQL statement list; Call the SQL multi-threaded query interface and assign a thread to query each SQL statement in the SQL statement list; After each thread query is completed, the query result is inserted into the query result record table, and the query progress of the user query record table is updated.
2. The multi-threaded SQL query and progress tracking method according to claim 1, characterized in that: The receiving of a user query request on a web page, querying SQL statements from an SQL configuration table, and assembling the queried SQL statements into an SQL statement list includes: Receive a user query request on the web page, and record the user query request in a user query record table; Call the SQL assembly interface, query SQL statements from the SQL configuration table according to the query options selected by the user, and assemble the queried SQL statements into a SQL statement list; Update the status of the user query record table to querying.
3. The multi-threaded SQL query and progress tracking method according to claim 1, characterized in that: Calling the SQL multi-threaded query interface and assigning a thread to query each SQL statement in the SQL statement list also includes: When all threads query successfully, update the status of the query result record table to success, call the Excel generation interface to generate an Excel file containing all query results, and update the Excel file path in the user query record table; If any query thread fails, the status of the user query record table is updated to failure, and the error information is recorded in the user query record table, and the status of the user query record table is no longer updated to other states.
4. The multi-threaded SQL query and progress tracking method according to claim 3, characterized in that: When all thread queries are successful, the method further includes: Call the Excel generation interface to generate an Excel file based on the data in the query result record table and save it on the server. Update the address of the generated Excel file on the server to the corresponding field of the user query record table.
5. The multi-threaded SQL query and progress tracking method according to claim 1, characterized in that: Also includes: The web page receives the Sql record query request, calls the Sql record query interface, and obtains the user query record from the user query record table.
6. The multi-threaded SQL query and progress tracking method according to claim 4, characterized in that: After generating the Excel file based on the data in the query result record table, it also includes: The web page receives the Excel download request, calls the Excel download interface, and checks whether the record status of the user's query request is successful in the query result record table. If so, a JSON string containing the Excel file download link is generated and sent to the web page.
7. The multi-threaded SQL query and progress tracking method according to claim 1, characterized in that: During the query process, the SQL multi-threaded query interface reflects the query progress in real time by updating the process field of the user query record table; Divide the query task into multiple threads. After each thread completes the query, increase the process value proportionally.
8. A multi-threaded SQL query and progress tracking system for use with the multi-threaded SQL query and progress tracking method according to any one of claims 1 to 7, characterized in that: Including web page, backend server and database: The web page is used to receive user query requests and display query progress and query results; The back-end server comprises: User query interface, used to process user query requests, call SQL assembly interface to assemble SQL statement list, call SQL multi-thread query interface to start multi-thread query; SQL assembly interface, used to query SQL statements from the SQL configuration table according to the query options selected by the user, and assemble the queried SQL statements into a SQL statement list; SQL multi-threaded query interface, used to execute SQL queries in multiple threads, update query progress and query result record table; SQL record query interface, used to obtain user query records from the user query record table according to the user name; Excel generation interface, used to generate Excel files according to the data in the query result record table, and update the file path of the user query record table; Excel download interface, used to provide a download link for the Excel file; The database includes: The user query record table is used to store the query record information of each user query operation; wherein the query record information includes the query code searchId, the user name username, the query status status, the query progress process, the creation time create_time of the query request and the excel storage path; sql configuration table, used to store executable SQL statements and their configuration information; The query result record table is used to store the query results of each user query operation.
9. An electronic device, It is characterized in that comprising a memory and a processor, wherein: The memory is used to store programs; The processor is coupled to the memory and is used to execute the program stored in the memory to implement the steps in the multi-threaded SQL query and progress tracking method described in any one of claims 1 to 7 above.
10. A computer-readable storage medium, characterized in that: Used to store computer-readable programs or instructions, which, when executed by a processor, can implement the steps in the multi-threaded SQL query and progress tracking method described in any one of claims 1 to 7 above.
