Report generation method, device, equipment and storage medium
By obtaining and verifying the target filtering condition array in the report generation request, determining the identification information and generating query statements, the problem of non-universal report interface is solved, and fast and flexible report file generation is achieved.
Patent Information
- Application Number
- CN202111558001.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-17
- Publication Date
- 2025-09-02
- Estimated Expiration
- 2041-12-17
AI Technical Summary
The existing report interface cannot be generalized, resulting in poor flexibility and universality of report query.
By obtaining the generation request of the report file, determining the target filtering condition array and identification information, performing checksum matching, generating a target query statement, and querying data based on the statement to output the report file.
It realizes the rapid generation of different report files, improves the generation speed and flexibility, and enhances the universality of table data query.
Smart Images

Figure CN114218254B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the financial field and the database field, and more specifically to a report generation method, apparatus, device, medium, and program product. Background Art
[0002] File-based reports are generated in a fixed format based on user-defined business query criteria, finding matching data from the system database. Due to the large amount of data required for file-based reports, asynchronous report generation is typically used for user download of query results.
[0003] In the process of realizing the inventive concept of the present disclosure, the inventors found that there are at least the following problems in the related technology: existing reports generally correspond to different report interfaces, and the report interfaces of different reports are not universal, resulting in poor flexibility and versatility of report queries. Summary of the Invention
[0004] In view of the above problems, the present disclosure provides a report generation method, apparatus, device, medium and program product.
[0005] According to a first aspect of the present disclosure, a report generation method is provided, comprising:
[0006] Obtaining a report file generation request, wherein the generation request includes a target screening condition array, the target screening condition array includes a target screening condition and a target screening value corresponding to the target screening condition, and the report file corresponds to multiple screening condition arrays;
[0007] Determining target identification information of the report file according to the target screening condition array, wherein the target identification information corresponds to basic configuration information, and the basic configuration information includes a first initial query statement corresponding to the target identification information;
[0008] Verify the above target screening condition array and output the verification result;
[0009] If the verification result indicates that the target screening condition array meets the verification rule, generating a target query statement according to the target screening condition array, the target identification information and the first initial query statement;
[0010] Perform data query based on the above target query statement and output the above report file.
[0011] According to an embodiment of the present disclosure, determining the target identification information of the report file according to the target screening condition array includes:
[0012] matching the target filtering condition and the target filtering value in the target filtering condition array according to the report interface configuration information, and outputting a matching result, wherein the report interface configuration information includes a plurality of report interface configuration tables, each of which includes identification information and at least one filtering condition array corresponding to the identification information;
[0013] When the matching result indicates a successful match, the target identification information is output.
[0014] According to an embodiment of the present disclosure, the target screening condition array is verified, and outputting the verification result includes:
[0015] Determining target screening condition configuration information according to the target identification information, wherein the target screening condition configuration information includes a verification rule corresponding to the target screening condition array;
[0016] The target screening conditions and the target screening values in the target screening condition array are respectively verified according to the verification rules, and the verification results are output.
[0017] According to an embodiment of the present disclosure, the above-mentioned verification rules include a screening condition mandatory input verification rule and a screening value format verification rule;
[0018] Verifying the target screening condition and the target screening value in the target screening condition array according to the verification rules includes:
[0019] Verify the target screening conditions according to the mandatory verification rules of the screening conditions; and
[0020] The target filter value is verified according to the filter value format verification rules.
[0021] According to an embodiment of the present disclosure, generating a target query statement based on the target screening condition array, the target identification information, and the first initial query statement includes:
[0022] Processing the target screening conditions and target screening values in the target screening condition array and outputting target screening information;
[0023] Generate a report generation task based on the target screening information and the target identification information;
[0024] The target query statement is generated according to the report generation task and the first initial query statement.
[0025] According to an embodiment of the present disclosure, the basic configuration information further includes a second initial query statement;
[0026] Generating the target query statement according to the report generation task and the first initial query statement includes:
[0027] Execute the report generation task, and generate a screening condition query statement based on the target screening information and the second initial query statement;
[0028] The target query statement is generated according to the screening condition query statement and the first initial query statement.
[0029] According to an embodiment of the present disclosure, performing data query based on the target query statement and outputting the report file include:
[0030] Obtain target data corresponding to the above report file through the above target query statement;
[0031] Fill the above target data into the report template and output the above report file.
[0032] According to an embodiment of the present disclosure, the report generation method further includes:
[0033] Displaying a report query page, wherein the report query page includes a filter condition selection area and a filter value selection area;
[0034] Responding to selection operations on the filtering condition selection area and the filtering value selection area, respectively, obtaining the target filtering condition and the target filtering value;
[0035] The generation request for the report file is generated according to the target screening condition and the target screening value.
[0036] A second aspect of the present disclosure provides a report generating apparatus, comprising:
[0037] an acquisition module, configured to acquire a report file generation request, wherein the generation request includes a target screening condition array, the target screening condition array includes a target screening condition and a target screening value corresponding to the target screening condition, and the report file corresponds to multiple screening condition arrays;
[0038] a determination module, configured to determine target identification information of the report file according to the target screening condition array, wherein the target identification information corresponds to basic configuration information, and the basic configuration information includes a first initial query statement corresponding to the target identification information;
[0039] A verification module is used to verify the target screening condition array and output the verification result;
[0040] a first generating module configured to generate a target query statement based on the target screening condition array, the target identification information, and the first initial query statement if the verification result indicates that the target screening condition array meets the verification rule;
[0041] The output module is used to perform data query based on the above target query statement and output the above report file.
[0042] A third aspect of the present disclosure provides an electronic device, comprising: one or more processors; and a memory for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors execute the above-mentioned report generation method.
[0043] A fourth aspect of the present disclosure further provides a computer-readable storage medium having executable instructions stored thereon, which, when executed by a processor, causes the processor to execute the above-mentioned report generating method.
[0044] A fifth aspect of the present disclosure further provides a computer program product, including a computer program, which implements the above-mentioned report generation method when executed by a processor. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] The above contents and other objects, features and advantages of the present disclosure will become more apparent through the following description of the embodiments of the present disclosure with reference to the accompanying drawings, in which:
[0046] Figure 1 A diagram schematically illustrates an application scenario of the report generation method, apparatus, device, medium, and program product according to an embodiment of the present disclosure;
[0047] Figure 2 The flowchart of the report generation method according to the embodiment of the present disclosure is schematically shown;
[0048] Figure 3 A flowchart of generating a target query statement according to a target screening condition array, target identification information and a first initial query statement is schematically shown according to an embodiment of the present disclosure;
[0049] Figure 4 A flowchart of a report generation method according to another embodiment of the present disclosure is schematically shown;
[0050] Figure 5 The following schematically illustrates an application scenario of the report generation method according to an embodiment of the present disclosure;
[0051] Figure 6 A schematic diagram of a structure of a report generating apparatus according to an embodiment of the present disclosure is shown; and
[0052] Figure 7The block diagram schematically shows an electronic device suitable for implementing the report generation method according to an embodiment of the present disclosure. DETAILED DESCRIPTION
[0053] Hereinafter, embodiments of the present disclosure will be described with reference to the accompanying drawings. However, it should be understood that these descriptions are merely exemplary and are not intended to limit the scope of the present disclosure. In the detailed description below, for ease of explanation, many specific details are set forth to provide a comprehensive understanding of the embodiments of the present disclosure. However, it is apparent that one or more embodiments may also be implemented without these specific details. In addition, in the following description, descriptions of well-known structures and technologies are omitted to avoid unnecessary confusion of the concepts of the present disclosure.
[0054] The terms used herein are only for describing specific embodiments and are not intended to limit the present disclosure. The terms "comprise," "include," etc. used herein indicate the presence of the features, steps, operations, and / or components, but do not exclude the presence or addition of one or more other features, steps, operations, or components.
[0055] All terms used herein (including technical and scientific terms) have the meanings commonly understood by those skilled in the art unless otherwise defined. It should be noted that the terms used herein should be interpreted as having a meaning consistent with the context of this specification and should not be interpreted in an idealized or overly rigid manner.
[0056] When expressions such as "at least one of A, B and C, etc." are used, they should generally be interpreted in accordance with the meaning of the expression commonly understood by those skilled in the art (for example, "a system having at least one of A, B and C" should include but is not limited to a system having A alone, B alone, C alone, A and B, A and C, B and C, and / or A, B, C, etc.).
[0057] In the technical solution disclosed herein, the collection, storage, use, processing, transmission, provision, disclosure and application of user personal information involved comply with the provisions of relevant laws and regulations, take necessary confidentiality measures, and do not violate public order and good morals.
[0058] In the technical solution disclosed herein, the acquisition, collection, storage, use, processing, transmission, provision, disclosure and application of data comply with the provisions of relevant laws and regulations, take necessary confidentiality measures, and do not violate public order and good morals.
[0059] In the technical solution disclosed herein, the user's authorization or consent is obtained before obtaining or collecting the user's personal information.
[0060] An embodiment of the present disclosure provides a report generation method, comprising: obtaining a generation request for a report file, wherein the generation request includes a target filtering condition array, the target filtering condition array includes target filtering conditions and target filtering values corresponding to the target filtering conditions, and the report file corresponds to multiple filtering condition arrays; determining target identification information of the report file according to the target filtering condition array, wherein the target identification information corresponds to basic configuration information, and the basic configuration information includes a first initial query statement corresponding to the target identification information; verifying the target filtering condition array and outputting a verification result; when the verification result indicates that the target filtering condition array meets the verification rules, generating a target query statement according to the target filtering condition array, the target identification information and the first initial query statement; performing data query based on the target query statement, and outputting a report file.
[0061] According to an embodiment of the present disclosure, target identification information for a report file is determined by using a target screening condition array containing target screening conditions and target screening values. Basic configuration information is determined based on the target identification information. If verification of the target screening condition array succeeds, a target query statement is generated based on the target screening condition array, the basic configuration information, and the target identification information. A report file is generated based on the target query statement, thereby avoiding encoding for different report files and improving the speed of report file generation. Furthermore, by adjusting the basic configuration information for different target identification information, different report files can be quickly generated, thereby enabling rapid generation of report files in response to varying business needs, thereby increasing the flexibility and versatility of table data queries.
[0062] Figure 1 The following schematically illustrates an application scenario of the report generation method according to an embodiment of the present disclosure.
[0063] like Figure 1 As shown, the application scenario 100 according to this embodiment may include terminal devices 101, 102, 103, a network 104, and a server 105. The network 104 is used as a medium for providing a communication link between the terminal devices 101, 102, 103 and the server 105. The network 104 may include various connection types, such as wired or wireless communication links or optical fiber cables.
[0064] Users can use terminal devices 101, 102, and 103 to interact with server 105 via network 104 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 101, 102, and 103, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc. (only as examples).
[0065] The terminal devices 101 , 102 , and 103 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, and desktop computers.
[0066] The server 105 may be a server that provides various services, such as a background management server (for example only) that supports websites browsed by users using the terminal devices 101, 102, and 103. The background management server may analyze and process received data such as user requests, and feed back processing results (such as web pages, information, or data obtained or generated according to user requests) to the terminal device.
[0067] It should be noted that the report generation method provided in the embodiments of the present disclosure can generally be executed by the server 105. Accordingly, the report generation apparatus provided in the embodiments of the present disclosure can generally be set in the server 105. The report generation method provided in the embodiments of the present disclosure can also be executed by a server or server cluster that is different from the server 105 and can communicate with the terminal devices 101, 102, 103 and / or the server 105. Accordingly, the report generation apparatus provided in the embodiments of the present disclosure can also be set in a server or server cluster that is different from the server 105 and can communicate with the terminal devices 101, 102, 103 and / or the server 105.
[0068] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is merely illustrative. Any number of terminal devices, networks and servers may be provided as required.
[0069] The following will be based on Figure 1 The scene described by Figures 2 to 5 The report generation method of the disclosed embodiment is described in detail.
[0070] Figure 2 The flowchart of the report generation method according to the embodiment of the present disclosure is schematically shown.
[0071] like Figure 2 As shown, the report generation method may include operations S210 to S250.
[0072] In operation S210 , a report file generation request is obtained, wherein the generation request includes a target filtering condition array, the target filtering condition array includes a target filtering condition and a target filtering value corresponding to the target filtering condition, and the report file corresponds to multiple filtering condition arrays.
[0073] According to an embodiment of the present disclosure, the target filtering condition may include a filtering condition for time, a filtering condition for category, etc. The target filtering value corresponding to the target filtering condition may include a value for defining the corresponding target filtering condition. For example, when the target filtering condition is a filtering condition for time, the target filtering value corresponding to the target filtering condition may include "1 to 10 years."
[0074] In operation S220 , target identification information of the report file is determined according to the target screening condition array, wherein the target identification information corresponds to basic configuration information, and the basic configuration information includes a first initial query statement corresponding to the target identification information.
[0075] According to an embodiment of the present disclosure, the target identification information of the report file may include identification information for representing the category of the report file, and different target identification information may represent different report file categories.
[0076] According to an embodiment of the present disclosure, the basic configuration information may include information required for generating a report file, such as report number information, text format information, field format information, etc. The first initial query statement may include a query statement in the basic configuration information corresponding to generating the report file. Because the basic configuration information corresponds to the target identification information, the corresponding basic configuration information can be determined based on the target identification information.
[0077] In operation S230 , the target screening condition array is verified and a verification result is output.
[0078] In operation S240 , if the verification result indicates that the target screening condition array meets the verification rule, a target query statement is generated according to the target screening condition array, the target identification information, and the first initial query statement.
[0079] According to an embodiment of the present disclosure, the target filter conditions and target filter values of the target filter condition array can be verified separately. For example, the format of the target filter value can be verified, or the necessity of the target filter condition can be verified. By verifying the target filter condition array, target filter conditions and target filter values that do not meet the verification rules can be filtered out, so that the generated target query statement can form a unified report interface, laying the foundation for the subsequent generation of target query statements.
[0080] In operation S250 , data query is performed based on the target query statement, and a report file is output.
[0081] According to an embodiment of the present disclosure, target identification information for a report file is determined by using a target screening condition array containing target screening conditions and target screening values. Basic configuration information is determined based on the target identification information. If verification of the target screening condition array succeeds, a target query statement is generated based on the target screening condition array, the basic configuration information, and the target identification information. A report file is generated based on the target query statement, thereby avoiding encoding for different report files and improving the speed of report file generation. Furthermore, by adjusting the basic configuration information for different target identification information, different report files can be quickly generated, thereby enabling rapid generation of report files in response to varying business needs, thereby increasing the flexibility and versatility of table data queries.
[0082] According to an embodiment of the present disclosure, determining target identification information of a report file according to a target screening condition array may include the following operations.
[0083] Match the target filtering conditions and target filtering values in the target filtering condition array according to the report interface configuration information, and output a matching result, wherein the report interface configuration information includes multiple report interface configuration tables, and the report interface configuration table includes identification information and at least one filtering condition array corresponding to the identification information; when the matching result indicates a successful match, output the target identification information.
[0084] According to an embodiment of the present disclosure, the identification information included in the report interface configuration table may be the ID information of the report interface configuration table. Since the identification information corresponds to at least one filter condition array, the filter condition array may include filter conditions and filter values. Matching the target filter conditions and target filter values in the target filter condition array based on the report interface configuration information may be performed by matching the filter conditions and filter values included in the filter condition array corresponding to the report interface configuration table with the target filter conditions and target filter values in the target filter condition array to obtain a matching result.
[0085] According to embodiments of the present disclosure, if the matching result indicates a successful match, target identification information is output, and a filter condition array corresponding to the report interface configuration table can be determined based on the target identification information. Furthermore, corresponding basic configuration information can be determined based on the target identification information to form a unified report interface, providing flexible configuration principles for subsequent report file generation.
[0086] It should be noted that, if the matching result representation does not match, the relevant personnel may be prompted that the target screening condition and the target screening value do not match, and need to re-edit the generation request of a new report file to implement the subsequent generation of the target query statement.
[0087] According to an embodiment of the present disclosure, verifying the target screening condition array and outputting the verification result may include the following operations.
[0088] Target filtering condition configuration information is determined based on the target identification information, wherein the target filtering condition configuration information includes verification rules corresponding to the target filtering condition array; the target filtering conditions and target filtering values in the target filtering condition array are verified respectively according to the verification rules, and the verification results are output.
[0089] According to an embodiment of the present disclosure, the verification rules include a screening condition mandatory input verification rule and a screening value format verification rule.
[0090] Verifying the target filtering condition and the target filtering value in the target filtering condition array according to the verification rules may include: verifying the target filtering condition according to the verification rule of the mandatory input of the filtering condition; and verifying the target filtering value according to the verification rule of the format of the filtering value.
[0091] According to an embodiment of the present disclosure, the target filtering condition configuration information may include a filtering condition array consisting of filtering conditions and filtering values.
[0092] According to an embodiment of the present disclosure, the filtering condition must-enter verification rule can be to verify the target filtering condition based on the filtering condition array contained in the report interface configuration table. When the filtering condition array contained in the report interface configuration table contains the target filtering condition, it can be determined that the target filtering condition meets the filtering condition must-enter verification rule.
[0093] The filter value format verification rule can be used to indicate whether the target filter value meets the format requirements of the target filter condition configuration information. If the target filter value in the target filter condition array meets the format requirements of the target filter condition configuration information, it can be determined that the target filter value meets the filter value format verification rule.
[0094] According to an embodiment of the present disclosure, by determining that the target filtering condition complies with the filtering condition mandatory input verification rule, and determining that the target filtering value complies with the filtering value format verification rule, it can be determined that the target filtering array complies with the verification rule, thereby providing a target filtering array that complies with the verification rule for generating a unified report interface.
[0095] Figure 3 A flowchart of generating a target query statement based on a target screening condition array, target identification information and a first initial query statement according to an embodiment of the present disclosure is schematically shown.
[0096] like Figure 3 As shown, operation 240, generating a target query statement according to the target screening condition array, the target identification information and the first initial query statement may include operations S310 to S330.
[0097] In operation S310 , the target screening conditions and target screening values in the target screening condition array are processed, and target screening information is output.
[0098] In operation S320 , a report generation task is generated according to the target screening information and the target identification information.
[0099] In operation S330 , a target query statement is generated according to the report generation task and the first initial query statement.
[0100] According to an embodiment of the present disclosure, the target filtering conditions and target filtering values in the target filtering condition array are processed by splicing the target filtering conditions and target filtering values using a preset format. The preset format can be, for example, a json format, with the target filtering condition as the key of the json object and the target filtering value as the value of the json object. The obtained target filtering information can be "{target filtering condition 1: target filtering value 1}, ..., {target filtering condition N: target filtering value N}".
[0101] According to the embodiments of the present disclosure, since the target filtering conditions and target filtering values comply with the above-mentioned verification rules, there is no need to perform differentiated processing on the target filtering conditions or target filtering values, so that the report generation task generated based on the target filtering information and target identification information can be applied to generate different report files, thereby realizing a universal report interface for generating report files.
[0102] According to an embodiment of the present disclosure, target screening information and target identification information may be written into a report generation task record to implement generation of a target query statement according to the report generation task and the first initial query statement.
[0103] According to an embodiment of the present disclosure, the basic configuration information may further include a second initial query statement.
[0104] Operation S330, generating a target query statement according to the report generation task and the first initial query statement, may include the following operations.
[0105] Execute the report generation task, generate a screening condition query statement according to the target screening information and the second initial query statement; and generate a target query statement according to the screening condition query statement and the first initial query statement.
[0106] According to an embodiment of the present disclosure, the second initial query statement may, for example, include query field information, sorting method information, deduplication method information, etc. For the same report file, different filtering conditions may correspond to the same second initial query statement. The target filtering information may be parsed to obtain the target filtering condition and the target filtering value. Based on the target filtering condition, the second initial query statement corresponding to the target filtering condition may be queried in the basic configuration information, and the variable in the second initial query statement may be replaced by the target filtering value to generate a filtering condition query statement. By combining the filtering condition query statement with the first initial query statement, the target query statement may be obtained.
[0107] According to an embodiment of the present disclosure, operation S250 , performing a data query based on a target query statement and outputting a report file may include the following operations.
[0108] Obtain target data corresponding to the report file through the target query statement; fill the target data into the report template and output the report file.
[0109] According to embodiments of the present disclosure, the target data may include data information stored in a database. By using the association between the target query statement and the target data, the target data corresponding to the target query statement can be obtained. By filling the target data into a report template, a report file can be automatically generated, thereby accelerating the generation of the report file and improving generation efficiency.
[0110] Figure 4 The following schematically shows a flow chart of a report generation method according to another embodiment of the present disclosure.
[0111] like Figure 4 As shown, the report generation method may further include operations S410 to S430.
[0112] In operation S410 , a report query page is displayed, wherein the report query page includes a filter condition selection area and a filter value selection area.
[0113] In operation S420 , a target filtering condition and a target filtering value are acquired in response to selection operations on the filtering condition selection area and the filtering value selection area, respectively.
[0114] In operation S430 , a report file generation request is generated according to the target screening condition and the target screening value.
[0115] According to embodiments of the present disclosure, by responding to selection operations in the filter condition selection area and the filter value selection area, a target filter condition and a target filter value are obtained, and a report file generation request is generated based on the target filter condition and the target filter value. Generating a report file generation request based on the selection operation of a relevant person simplifies the steps for generating a report file and improves report generation efficiency.
[0116] Figure 5 The application scenario diagram of the report generation method according to the embodiment of the present disclosure is schematically shown.
[0117] like Figure 5 As shown, a report query page 500 may be displayed, and the report query page 500 includes filter condition selection areas 511 , 521 , and 531 and filter value selection areas 512 , 522 , and 532 .
[0118] When a selection operation is detected for the filter condition selection area 511, the target filter condition can be obtained as "Filter condition 1". When a selection operation is detected for the filter value selection area 512, "Filter value 1" corresponding to "Filter condition 1" can be obtained, that is, "Filter value 1" is determined as the target filter value.
[0119] According to the “filter condition 1” and the “filter value 1”, a target filter array 510 included in the report file generation request may be generated.
[0120] The same method can be used to generate target screening array 520 and target screening array 530. The report file generation request can include target screening arrays 510, 520, and 530.
[0121] Based on the above report generation method, the present disclosure also provides a report generation device. Figure 6 The device is described in detail.
[0122] Figure 6 The structure block diagram of the report generating device according to an embodiment of the present disclosure is schematically shown.
[0123] like Figure 6 As shown, the report generating apparatus 600 includes an acquisition module 610 , a determination module 620 , a verification module 630 , a first generation module 640 and an output module 650 .
[0124] The acquisition module 610 is used to acquire a report file generation request, wherein the generation request includes a target filtering condition array, the target filtering condition array includes a target filtering condition and a target filtering value corresponding to the target filtering condition, and the report file corresponds to multiple filtering condition arrays.
[0125] The determination module 620 is configured to determine target identification information of the report file according to the target screening condition array, wherein the target identification information corresponds to basic configuration information, and the basic configuration information includes a first initial query statement corresponding to the target identification information.
[0126] The verification module 630 is used to verify the target screening condition array and output the verification result.
[0127] The first generating module 640 is configured to generate a target query statement according to the target screening condition array, the target identification information and the first initial query statement when the verification result indicates that the target screening condition array meets the verification rule.
[0128] The output module 650 is used to perform data query based on the target query statement and output a report file.
[0129] According to an embodiment of the present disclosure, the determination module may include: a matching unit and a target identification information output unit.
[0130] A matching unit is used to match the target filtering conditions and target filtering values in the target filtering condition array according to the report interface configuration information, and output the matching results, wherein the report interface configuration information includes multiple report interface configuration tables, and the report interface configuration table includes identification information and at least one filtering condition array corresponding to the identification information.
[0131] The target identification information output unit is used to output the target identification information when the matching result indicates that the match is successful.
[0132] According to an embodiment of the present disclosure, the verification module may include: a first determination unit and a verification result output unit.
[0133] The first determining unit is configured to determine target screening condition configuration information according to the target identification information, wherein the target screening condition configuration information includes a verification rule corresponding to the target screening condition array.
[0134] The verification result output unit is used to verify the target screening conditions and target screening values in the target screening condition array according to the verification rules and output the verification results.
[0135] According to an embodiment of the present disclosure, the verification rules may include a screening condition mandatory input verification rule and a screening value format verification rule.
[0136] The verification result output unit may include: a first syndrome unit and a second syndrome unit.
[0137] The first verification subunit is used to verify the target screening condition according to the screening condition mandatory verification rule.
[0138] The second verification subunit is used to verify the target screening value according to the screening value format verification rule.
[0139] According to an embodiment of the present disclosure, the first generating module may include: a processing unit, a report generation task generating unit, and a target query statement generating unit.
[0140] The processing unit is used to process the target filtering conditions and target filtering values in the target filtering condition array and output target filtering information.
[0141] The report generation task generating unit is used to generate a report generation task according to the target screening information and the target identification information.
[0142] The target query statement generating unit is configured to generate a target query statement according to the report generation task and the first initial query statement.
[0143] According to an embodiment of the present disclosure, the basic configuration information may further include a second initial query statement.
[0144] The target query statement generating unit may include: a screening condition query statement generating subunit and a target query statement generating subunit.
[0145] The screening condition query statement generating subunit is used to execute the report generation task and generate the screening condition query statement according to the target screening information and the second initial query statement.
[0146] The target query statement generating subunit is configured to generate a target query statement according to the screening condition query statement and the first initial query statement.
[0147] According to an embodiment of the present disclosure, the output module may include: a target data acquiring unit and a filling unit.
[0148] The target data acquisition unit is used to acquire target data corresponding to the report file through a target query statement.
[0149] The filling unit is used to fill the target data into the report template and output the report file.
[0150] According to an embodiment of the present disclosure, the report generating apparatus may further include: a presentation module, a response module, and a generation request generating module.
[0151] The display module is used to display the report query page, wherein the report query page includes a filter condition selection area and a filter value selection area.
[0152] The response module is used to obtain the target filtering condition and the target filtering value in response to the selection operations on the filtering condition selection area and the filtering value selection area respectively.
[0153] The generation request generation module is used to generate a generation request for a report file according to target filtering conditions and target filtering values.
[0154] According to an embodiment of the present disclosure, any multiple modules among the acquisition module 610, the determination module 620, the verification module 630, the first generation module 640, and the output module 650 can be combined into one module for implementation, or any one of the modules can be split into multiple modules. Alternatively, at least part of the functions of one or more of these modules can be combined with at least part of the functions of other modules and implemented in one module. According to an embodiment of the present disclosure, at least one of the acquisition module 610, the determination module 620, the verification module 630, the first generation module 640, and the output module 650 can be at least partially implemented as a hardware circuit, such as a field programmable gate array (FPGA), a programmable logic array (PLA), a system on a chip, a system on a substrate, a system on a package, an application specific integrated circuit (ASIC), or can be implemented by hardware or firmware such as any other reasonable way of integrating or packaging the circuit, or implemented in any one of the three implementation methods of software, hardware, and firmware, or in an appropriate combination of any of them. Alternatively, at least one of the acquisition module 610 , the determination module 620 , the verification module 630 , the first generation module 640 , and the output module 650 may be at least partially implemented as a computer program module, which may perform corresponding functions when executed.
[0155] Figure 7 The block diagram schematically shows an electronic device suitable for implementing the report generation method according to an embodiment of the present disclosure.
[0156] like Figure 7 As shown, the electronic device 700 according to an embodiment of the present disclosure includes a processor 701, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 702 or a program loaded from a storage part 708 into a random access memory (RAM) 703. The processor 701 may, for example, include a general-purpose microprocessor (e.g., a CPU), an instruction set processor and / or a related chipset and / or a special-purpose microprocessor (e.g., an application-specific integrated circuit (ASIC)), etc. The processor 701 may also include an onboard memory for caching purposes. The processor 701 may include a single processing unit or multiple processing units for performing different actions of the method flow according to an embodiment of the present disclosure.
[0157] Various programs and data required for the operation of the electronic device 700 are stored in the RAM 703. The processor 701, ROM 702, and RAM 703 are connected to each other via a bus 704. The processor 701 executes the various operations of the method flow according to the embodiment of the present disclosure by executing the programs in the ROM 702 and / or RAM 703. It should be noted that the programs may also be stored in one or more memories other than the ROM 702 and RAM 703. The processor 701 may also execute the various operations of the method flow according to the embodiment of the present disclosure by executing the programs stored in the one or more memories.
[0158] According to an embodiment of the present disclosure, the electronic device 700 may further include an input / output (I / O) interface 705, which is also connected to the bus 704. The electronic device 700 may further include one or more of the following components connected to the I / O interface 705: an input portion 706 including a keyboard, a mouse, etc.; an output portion 707 including devices such as a cathode ray tube (CRT), a liquid crystal display (LCD), and a speaker; a storage portion 708 including a hard disk; and a communication portion 709 including a network interface card such as a LAN card or a modem. The communication portion 709 performs communication processing via a network such as the Internet. A drive 710 is also connected to the I / O interface 705 as needed. A removable medium 711, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed in the drive 710 as needed, so that a computer program read therefrom can be installed into the storage portion 708 as needed.
[0159] The present disclosure also provides a computer-readable storage medium, which may be included in the device / apparatus / system described in the above embodiments, or may exist independently and not be incorporated into the device / apparatus / system. The computer-readable storage medium carries one or more programs, and when executed, implements the method according to the embodiments of the present disclosure.
[0160] According to an embodiment of the present disclosure, a computer-readable storage medium may be a non-volatile computer-readable storage medium, for example, it may include but is not limited to: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, apparatus, or device. For example, according to an embodiment of the present disclosure, a computer-readable storage medium may include the ROM 702 and / or RAM 703 described above and / or one or more memories other than ROM 702 and RAM 703.
[0161] The embodiments of the present disclosure also include a computer program product, which includes a computer program containing program code for executing the method shown in the flowchart. When the computer program product is run in a computer system, the program code is used to enable the computer system to implement the report generation method provided by the embodiments of the present disclosure.
[0162] The computer program executes the above functions defined in the system / device of the embodiment of the present disclosure when the processor 701 executes the computer program. According to the embodiment of the present disclosure, the system, device, module, unit, etc. described above can be implemented by a computer program module.
[0163] In one embodiment, the computer program may be stored on a tangible storage medium such as an optical storage device or a magnetic storage device. In another embodiment, the computer program may be transmitted and distributed in the form of a signal on a network medium, downloaded and installed via the communication portion 709, and / or installed from a removable medium 711. The program code contained in the computer program may be transmitted using any appropriate network medium, including but not limited to wireless, wired, or any suitable combination thereof.
[0164] In such an embodiment, the computer program can be downloaded and installed from a network via the communication section 709, and / or installed from a removable medium 711. When the computer program is executed by the processor 701, the above-described functions defined in the system of the embodiment of the present disclosure are performed. According to the embodiment of the present disclosure, the systems, devices, means, modules, units, etc. described above can be implemented by computer program modules.
[0165] According to an embodiment of the present disclosure, the program code for executing the computer program provided by the embodiment of the present disclosure can be written in any combination of one or more programming languages. Specifically, these computer programs can be implemented using high-level procedural and / or object-oriented programming languages, and / or assembly / machine languages. Programming languages include, but are not limited to, languages such as Java, C++, python, "C" or similar programming languages. The program code can be executed entirely on the user computing device, partially on the user device, partially on a remote computing device, or entirely on a remote computing device or server. In cases involving a remote computing device, the remote computing device can be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computing device (for example, using an Internet service provider to connect via the Internet).
[0166] The flowcharts and block diagrams in the accompanying drawings illustrate the possible implementation architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each box in the flowchart or block diagram can represent a module, program segment, or a part of code, and the above-mentioned module, program segment, or a part of code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in an order different from that marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flowchart, and the combination of boxes in the block diagram or flowchart, can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0167] Those skilled in the art will appreciate that the features described in the various embodiments and / or claims of this disclosure may be combined and / or coupled in various ways, even if such combinations and / or couplings are not explicitly described in this disclosure. In particular, the features described in the various embodiments and / or claims of this disclosure may be combined and / or coupled in various ways without departing from the spirit and teachings of this disclosure. All such combinations and / or couplings are intended to fall within the scope of this disclosure.
[0168] The embodiments of the present disclosure are described above. However, these embodiments are for illustrative purposes only and are not intended to limit the scope of the present disclosure. Although each embodiment has been described separately above, this does not mean that the measures in each embodiment cannot be used in combination to advantage. The scope of the present disclosure is defined by the appended claims and their equivalents. Without departing from the scope of the present disclosure, those skilled in the art may make various substitutions and modifications, which should all fall within the scope of the present disclosure.
Claims
1. A report generation method, comprising: Obtaining a report file generation request, wherein the generation request includes a target screening condition array, the target screening condition array includes a target screening condition and a target screening value corresponding to the target screening condition, and the report file corresponds to multiple screening condition arrays; matching the target filtering condition and the target filtering value in the target filtering condition array according to identification information of a report interface configuration table in the report interface configuration information and at least one filtering condition array corresponding to the identification information, and outputting a matching result, wherein the report interface configuration information includes a plurality of the report interface configuration tables; If the matching result indicates a successful match, outputting target identification information corresponding to the target screening condition array, wherein basic configuration information corresponding to the target identification information is used to represent respective report interfaces of different target screening condition arrays, and the basic configuration information includes a first initial query statement corresponding to the target identification information; Determine, according to the target identification information, a screening condition mandatory input verification rule and a screening value format verification rule corresponding to the target screening condition array; Verify the target screening condition according to the screening condition must-enter verification rule; Verify the target screening value according to the screening value format verification rule and output the verification result; If the verification result indicates that the target screening condition array meets the verification rule, generating a target query statement according to the target screening condition array, the target identification information and the first initial query statement; Perform data query based on the target query statement and output the report file.
2. The method according to claim 1, wherein Generating a target query statement according to the target screening condition array, target identification information, and the first initial query statement includes: Processing the target screening conditions and target screening values in the target screening condition array, and outputting target screening information; generating a report generation task according to the target screening information and the target identification information; The target query statement is generated according to the report generation task and the first initial query statement.
3. The method according to claim 2, wherein: The basic configuration information also includes a second initial query statement; Generating the target query statement according to the report generation task and the first initial query statement includes: Executing the report generation task, generating a screening condition query statement according to the target screening information and the second initial query statement; The target query statement is generated according to the screening condition query statement and the first initial query statement.
4. The method according to claim 1, wherein The performing of data query based on the target query statement and outputting the report file comprises: Acquire target data corresponding to the report file through the target query statement; Fill the target data into the report template and output the report file.
5. The method according to claim 1, further comprising: Displaying a report query page, wherein the report query page includes a filter condition selection area and a filter value selection area; acquiring the target filtering condition and the target filtering value in response to selection operations on the filtering condition selection area and the filtering value selection area respectively; The generation request of the report file is generated according to the target screening condition and the target screening value.
6. A report generating device comprising: an acquisition module, configured to acquire a report file generation request, wherein the generation request includes a target screening condition array, the target screening condition array includes a target screening condition and a target screening value corresponding to the target screening condition, and the report file corresponds to multiple screening condition arrays; a determination module, configured to determine target identification information of the report file according to the target screening condition array, wherein the target identification information corresponds to basic configuration information, and the basic configuration information includes a first initial query statement corresponding to the target identification information; A verification module, configured to verify the target screening condition array and output a verification result; a first generating module, configured to generate a target query statement according to the target screening condition array, the target identification information, and the first initial query statement if the verification result indicates that the target screening condition array meets the verification rule; An output module, configured to perform data query based on the target query statement and output the report file; Wherein, the determination module is configured as follows: matching the target filtering condition and the target filtering value in the target filtering condition array according to identification information of a report interface configuration table in the report interface configuration information and at least one filtering condition array corresponding to the identification information, and outputting a matching result, wherein the report interface configuration information includes a plurality of the report interface configuration tables; When the matching result indicates a successful match, outputting the target identification information corresponding to the target screening condition array, wherein the basic configuration information corresponding to the target identification information is used to represent the respective report interfaces of different target screening condition arrays; The verification module is configured as follows: Determine, according to the target identification information, a screening condition mandatory input verification rule and a screening value format verification rule corresponding to the target screening condition array; Verify the target screening condition according to the screening condition must-enter verification rule; The target screening value is verified according to the screening value format verification rule, and the verification result is output.
7. An electronic device comprising: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors are enabled to execute the method according to any one of claims 1 to 5.
8. A computer-readable storage medium having executable instructions stored thereon, which, when executed by a processor, causes the processor to perform the method according to any one of claims 1 to 5.
9. A computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the method according to any one of claims 1 to 5 is implemented.
Citation Information
Patent Citations
Method and device for extracting data
CN110109947A
Data query method and device
CN113760948A