Data verification method and device based on software robot
Through the data verification method based on software robots, the account data before and after the merge is automatically compared, which solves the problems of low manual verification efficiency and unstable accuracy in the prior art, and achieves efficient and accurate data verification.
Patent Information
- Application Number
- CN202510353115.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-25
- Publication Date
- 2025-04-25
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
In the prior art, relying on manual account data verification is inefficient, time-consuming and unstable. Especially after the organization merges, due to the large amount of data and possible inconsistencies, an efficient and accurate data verification method is needed.
The data verification method based on the software robot is adopted. By determining the restrictions and output fields, the historical data before and after the merge is obtained, the files to be compared are generated, and the software robot is automatically compared and the verification results are output.
It improves the efficiency and accuracy of data verification, reduces the verification time, enhances the stability of the results, and avoids manual errors.
Smart Images

Figure CN119884137A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of testing, and in particular to a data verification method and device based on a software robot. Background Art
[0002] After two institutions of the same level are merged, the merged institution will be treated as a subordinate branch of the other institution. The account data of the merged institution will be offset in the month of the merger. At the same time, the historical account data of the merged institution will be incorporated into the account data of the other institution in the current month in the form of account correspondence. Due to the large amount of data involved, there may be inconsistencies in the account data before and after the merger, so the relevant account data needs to be verified.
[0003] The existing technology mainly exports the data before and after the merger manually, and then manually verifies the exported data.
[0004] Since the account data is relatively large, manual verification is inefficient, time-consuming and the accuracy of the verification is unstable. Summary of the invention
[0005] The embodiments of the present application provide a data verification method and device based on a software robot, which can improve the efficiency and accuracy of data verification.
[0006] In a first aspect, an embodiment of the present application provides a data verification method based on a software robot, the method being applied to a computing device, comprising:
[0007] identifying at least one constraint;
[0008] Acquire first historical data corresponding to the first institution and second historical data corresponding to the second institution based on the restriction condition, wherein the first historical data is data corresponding to the first institution before the merger, and the second historical data is data corresponding to the second institution after the merger;
[0009] determining at least one output field;
[0010] Determine a first target value corresponding to each output field in the first historical data, and obtain a first file to be compared based on each first target value;
[0011] Determine a second target value corresponding to each output field in the second historical data, and obtain a second file to be compared based on each second target value;
[0012] The first file to be compared and the second file to be compared are automatically verified based on a software robot to output a verification result.
[0013] In a possible implementation, automatically verifying the first file to be compared and the second file to be compared based on a software robot to output a verification result includes:
[0014] Automatically verifying in sequence based on a software robot whether a first target value corresponding to each output field in the first file to be compared is equal to a second target value corresponding to each output field in the second file to be compared;
[0015] If the first target value corresponding to each output field in the first file to be compared is equal to the second target value corresponding to each output field in the second file to be compared, then output a verification result without abnormality;
[0016] If the first target value corresponding to at least one output field in the first file to be compared is not equal to the corresponding second target value in the second file to be compared, an abnormal result file is determined, and the abnormal verification result and the abnormal result file are output.
[0017] In a possible implementation, automatically verifying in sequence based on a software robot whether a first target value corresponding to each output field in the first file to be compared is equal to a second target value corresponding to each output field in the second file to be compared includes:
[0018] Determine a preset first field from the output fields;
[0019] Determine the remaining output fields except the first field as conditional columns;
[0020] Based on the principle of consistency of condition columns, the data in the first file to be compared and the data in the second file to be compared are merged to obtain corresponding multiple pieces of union data;
[0021] Determine the file to be compared to which each piece of union data belongs;
[0022] If the union data belongs to both the first file to be compared and the second file to be compared, adding a first mark to the union data;
[0023] If the union data only belongs to the first file to be compared, adding a second mark to the union data;
[0024] If the union data only belongs to the second file to be compared, adding a third mark to the union data;
[0025] For the union data marked with the first mark, it is determined whether the first target value corresponding to the first field in the first file to be compared is equal to the second target value corresponding to the first field in the second file to be compared.
[0026] In a possible implementation, the determining of the abnormal result file includes:
[0027] Write each added union data marked as the first mark into the first file, write each added union data marked as the second mark into the second file, and write each added union data marked as the third mark into the third file;
[0028] The first file, the second file and the third file are constructed as the abnormal result file.
[0029] In a possible implementation, the method further includes:
[0030] The acquired first historical data and second historical data are saved locally.
[0031] In a possible implementation manner, the step of saving the acquired first historical data and second historical data locally includes:
[0032] The step of saving the acquired first historical data and second historical data locally includes:
[0033] Determine a first folder corresponding to the first institution, and a second folder corresponding to the second institution;
[0034] The first historical data is saved in the first folder, and the second historical data is saved in a second folder.
[0035] In a possible implementation manner, determining a first folder corresponding to the first institution and a second folder corresponding to the second institution includes:
[0036] Determine the code, general ledger account, start download time and end download time corresponding to the first institution, and name the locally preset folder based on the code, general ledger account, start download time and end download time corresponding to the first institution to obtain a first folder;
[0037] Determine the code, general ledger account, start download time and end download time corresponding to the second institution, and name the locally preset folder based on the code, general ledger account, start download time and end download time corresponding to the second institution to obtain a second folder.
[0038] In a second aspect, the present application provides a data verification device based on a software robot, the device being applied to a computing device, comprising:
[0039] A determination module, used to determine at least one constraint condition;
[0040] an acquisition module, configured to acquire first historical data corresponding to the first institution and second historical data corresponding to the second institution based on the restriction condition, wherein the first historical data is data corresponding to the first institution before the merger, and the second historical data is data corresponding to the second institution after the merger;
[0041] The determination module is further used to determine at least one output field;
[0042] The determination module is further used to determine a first target value corresponding to each output field in the first historical data, and obtain a first file to be compared based on each first target value;
[0043] The determination module is further used to determine a second target value corresponding to each output field in the second historical data, and obtain a second file to be compared based on each second target value;
[0044] The processing module is used to automatically verify the first file to be compared and the second file to be compared based on a software robot to output a verification result.
[0045] In a third aspect, the present application provides a computer device, including: a memory, a processor;
[0046] The memory stores computer-executable instructions;
[0047] The processor executes the computer-executable instructions stored in the memory, so that the processor performs the above-mentioned method.
[0048] In a fourth aspect, the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to implement the method as described above when executed by a processor.
[0049] In a fifth aspect, the present application provides a computer program product, including a computer program, which implements the method described above when executed by a processor.
[0050] The data verification method and device based on software robots provided in the embodiments of the present application determine at least one restriction condition, obtain the first historical data corresponding to the first mechanism before the merger and the second historical data corresponding to the second mechanism after the merger based on the restriction condition, determine the output field, determine the first target value corresponding to each output field in the first historical data, obtain the first file to be compared based on each first target value, and determine the second target value corresponding to each output field in the second historical data, obtain the second file to be compared based on each second target value, and automatically verify the first file to be compared and the second file to be compared based on the software robot to output the verification result. The present application can automatically verify the first comparison file and the second comparison file through the software robot, which can speed up the verification efficiency and shorten the verification time. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0052] Figure 1 Schematic diagram of the scenario provided for this application;
[0053] Figure 2 The process of verifying data for existing technologies;
[0054] Figure 3 Schematic diagram of the process of the data verification method based on software robot provided in this application Figure 1 ;
[0055] Figure 4 The constraints and output fields corresponding to the first merged organization of the example;
[0056] Figure 5 The constraints and output fields corresponding to the second mechanism incorporated in the example;
[0057] Figure 6 Schematic diagram of the process of the data verification method based on software robot provided in this application Figure 2 ;
[0058] Figure 7 This is a schematic diagram of naming the files to be compared as an example;
[0059] Figure 8 is a schematic diagram of the first file to be compared as an example;
[0060] Fig. 9 is a schematic diagram of a second file to be compared as an example;
[0061] Fig.10 Schematic diagram of the process of the data verification method based on software robot provided in this application Figure 3 ;
[0062] Fig.11 Schematic diagram of the union data for the example;
[0063] Fig.12 Schematic diagram of the process of the data verification method based on software robot provided in this application Figure 4 ;
[0064] Fig.13 A schematic diagram of the first file of the example;
[0065] Fig.14 A schematic diagram of a second file as an example;
[0066] Fig.15 A schematic diagram of the third file of the example;
[0067] Fig.16 Schematic diagram of the process of the data verification method based on software robot provided in this application Figure 5 ;
[0068] Fig.17 Schematic diagram of the process of the data verification method based on software robot provided in this application Figure 6 ;
[0069] Fig.18 A schematic diagram of the structure of a data verification device based on a software robot provided in this application;
[0070] Fig.19 A schematic diagram of the structure of the electronic device provided in this application.
[0071] The above drawings have shown clear embodiments of the present application, which will be described in more detail later. These drawings and text descriptions are not intended to limit the scope of the present application in any way, but to illustrate the concept of the present application to those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION
[0072] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present application. Instead, they are merely examples of devices and methods consistent with some aspects of the present application as detailed in the appended claims.
[0073] First, the terms involved in this application are explained:
[0074] Robotic Process Automation (RPA) is a technology that automates business processes by using software robots to simulate human operations on computers.
[0075] Figure 1 The scenario diagram provided for this application is that after two institutions of the same level merge, for example, the first institution merges with the second institution, the merged first institution will be used as a subordinate branch of the second institution, and the account data of the first institution will be offset in the month of the merger, and the historical data of the first institution will be merged into the account data of the other institution in the current month. Due to the large amount of data involved, there may be inconsistencies in the account data before and after the merger, so it is necessary to verify the data of the first institution before the merger and the data of the second institution after the merger. Figure 1 As shown, the computing device 1 is the executor of data verification, which can be selected as a computing server with computing capabilities. The computing device 1 verifies the data of the first institution before the merger and the data of the second institution after the merger, and obtains and outputs the corresponding verification result.
[0076] Figure 2 The existing technology mainly involves the relevant operation and maintenance personnel exporting account data in the background, the relevant financial personnel cleaning the account data, and manually uploading the manual vouchers after aggregation. Finally, the financial personnel manually check the account data to complete the verification of the account data before and after merging. However, since the account data to be verified is relatively large, manual verification is inefficient, which takes a long time and the accuracy of the verification is unstable.
[0077] The data verification method based on software robots provided in the embodiment of the present application first determines at least one restriction condition, obtains the first historical data corresponding to the first mechanism before the merger and the second historical data corresponding to the second mechanism after the merger based on the restriction condition, determines the output field, determines the first target value corresponding to each output field in the first historical data, obtains the first file to be compared based on each first target value, and determines the second target value corresponding to each output field in the second historical data, obtains the second file to be compared based on each second target value, and automatically verifies the first file to be compared and the second file to be compared based on the software robot to output the verification result. The present application can automatically verify the first comparison file and the second comparison file through the software robot, which can speed up the verification efficiency and shorten the verification time.
[0078] The technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems are described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.
[0079] Figure 3 Schematic diagram of the process of the data verification method based on software robot provided in this application Figure 1 ,The method is applied to computing devices, such as Figure 3 As shown, including:
[0080] S301. Determine at least one restriction condition.
[0081] Combined with the scenario examples, the restriction conditions can be determined according to the actual situation, such as the download batch number, download year and month, organization code, general ledger account, financial document voucher status flag, etc.
[0082] S302. Based on the restriction condition, obtain first historical data corresponding to the first institution and second historical data corresponding to the second institution, wherein the first historical data is the data corresponding to the first institution before the merger, and the second historical data is the data corresponding to the second institution after the merger.
[0083] In combination with the scenario example, the first organization can be the organization to be incorporated, and the second organization can be the organization incorporated by the first structure. Before the first structure is incorporated into the second organization, the corresponding first historical data can be captured from the first organization based on the above-mentioned restriction conditions. Then, after the first organization is incorporated into the second organization, the corresponding second historical data can be captured from the second organization based on the above-mentioned restriction conditions.
[0084] S303: Determine at least one output field.
[0085] Combined with the scenario example, the first historical data and the second historical data include multiple fields, which can be checked to determine the output field, so that the final output data can display the checked output field. The output fields can include: general ledger account, insurance type (including insurance type 1 and insurance type 2), channel 1, channel 2, individual group insurance identification, policy year, insurance type code, false loan identification, number of items and amount, etc.
[0086] Figure 4 The constraints and output fields corresponding to the first merged organization are as follows: Figure 4As shown, the input restriction conditions corresponding to the first institution include: download batch number, download year and month, institution code, general ledger account, and financial document voucher status flag; the corresponding output fields, that is, the checked fields include: general ledger account, insurance type (including insurance type 1 and insurance type 2), channel 1, channel 2, individual group insurance identification, policy year, insurance type code, false loan identification, number of items and amount.
[0087] Figure 5 The constraints and output fields corresponding to the second mechanism incorporated in the example are as follows: Figure 5 As shown, the input restriction conditions corresponding to the second institution include: download batch number, download year and month, institution code, general ledger account, and financial document voucher status flag, where the download batch number can be a preset ; The corresponding output fields, that is, the selected fields include: general ledger account, insurance type (including insurance type 1 and insurance type 2), channel 1, channel 2, individual group insurance identification, policy year, insurance type code, false loan identification, number of items and amount.
[0088] S304: Determine a first target value corresponding to each output field in the first historical data, and obtain a first file to be compared based on each first target value.
[0089] In combination with the scenario example, based on the output fields determined above, the specific values corresponding to each output field are captured from the first historical data to obtain the first file to be compared, which may be an Excel file. The first file to be compared may be saved to a local folder.
[0090] S305: Determine a second target value corresponding to each output field in the second historical data, and obtain a second file to be compared based on each second target value.
[0091] In combination with the scenario example, based on the output fields determined above, the specific values corresponding to each output field are captured from the second historical data to obtain the second file to be compared, which may be an Excel file. The first file to be compared may be saved to a local folder.
[0092] S306: Automatically verify the first file to be compared and the second file to be compared based on a software robot to output a verification result.
[0093] Combined with the scenario example, based on PRA technology, the first target value corresponding to each output field of each data in the first file to be compared is compared with the second target value corresponding to each output field of each data in the second file to be compared in turn to determine whether each data in the first file to be compared is equal to each data in the second file to be compared, and the comparison result is determined as the verification result.
[0094] In this example, the first comparison file and the second comparison file can be automatically verified by a software robot, which can increase the verification efficiency and shorten the verification time.
[0095] Optional, Figure 6 Schematic diagram of the process of the data verification method based on software robot provided in this application Figure 2 ,like Figure 6 Said S306 includes:
[0096] S601: Automatically verify, based on a software robot, whether a first target value corresponding to each output field in the first file to be compared is equal to a second target value corresponding to each output field in the second file to be compared.
[0097] Combined with the scenario example, the first file to be compared and the second file to be compared can both contain multiple data, each data includes the target value corresponding to each output field, and the preset script can be used to compare the target value of each output of the data to determine whether they are equal. Specifically, the do_excel.py file under the preset file can be run, and the modules os and pandas to be used can be imported. The object path containing the absolute path of the parent menu of this file and the object path4 containing the absolute path of accountData can be obtained through the os.path method. The function get_all_filenames_in_subdirectories is defined, and the function is called with path4 as a parameter to traverse the folder accountData and all its subdirectories, and the object filenames containing all the file names under accountData is generated. The information in the filenames object is read and compared in a loop to complete the comparison of the first file to be compared and the second file to be compared. Specifically, the fields consisting of the 1st to 7th characters and the fields consisting of the 9th to 15th characters of the two files to be compared are read respectively. Figure 7 The following is a schematic diagram of the naming of the files to be compared as an example: Figure 7 The field composed of the 1st to 7th characters is the corresponding starting year and month, and the field composed of the 9th to 15th characters is the corresponding ending year and month. If the field composed of the 1st to 7th characters is equal to the field composed of the 9th to 15th characters, for example, both are 2023010, where "010" is a three-digit month, then the folder is determined to be the second file to be compared. If the field composed of the 1st to 7th characters is not equal to the field composed of the 9th to 15th characters, for example, 2023001 and 2023009 respectively, then the folder is determined to be the first file to be compared.
[0098] S602: If the first target value corresponding to each output field in the first file to be compared is equal to the second target value corresponding to each output field in the second file to be compared, output a verification result without abnormality.
[0099] Combined with the scenario example, if the number of data contained in the first file to be compared is equal to that in the second file to be compared, for example, the first file to be compared includes four data, namely data m1, data m2, data m3 and data m4, and the first file to be compared also includes four data, namely data n1, data n2, data n3 and data n4, and the first target value corresponding to each output field in data m1 is equal to the second target value corresponding to each output field in data n1, the first target value corresponding to each output field in data m2 is equal to the second target value corresponding to each output field in data n2, the first target value corresponding to each output field in data m3 is equal to the second target value corresponding to each output field in data n3, and the first target value corresponding to each output field in data m4 is equal to the second target value corresponding to each output field in data n4, so it can be determined that the first file to be compared is equal to the second file to be compared.
[0100] S603. If the first target value corresponding to at least one output field in the first file to be compared is not equal to the corresponding second target value in the second file to be compared, an abnormal result file is determined, and the abnormal verification result and the abnormal result file are output.
[0101] In combination with the scenario example, if the amount of data contained in the first file to be compared is not equal to the amount of data contained in the second file to be compared, for example, Figure 8 is a schematic diagram of the first price comparison file of the example, such as Figure 8 As shown, the first price comparison file includes four pieces of data as examples. Fig. 9 is a schematic diagram of the second price comparison file as an example. Fig. 9 As shown, the second file to be compared includes three pieces of data in the example. Or the first target value of the output field in the first file to be compared is not equal to the second target value in the second file to be compared. For example, the third piece of data in the first file to be compared does not exist in the second file to be compared, so it can be determined that the first file to be compared is not equal to the second file to be compared.
[0102] Based on the method provided in this example, the purpose of comparing the first file to be compared with the second file to be compared can be achieved.
[0103] Optional, Fig.10 Schematic diagram of the process of the data verification method based on software robot provided in this application Figure 3 ,like Fig.10 Said, S601 includes:
[0104] S1001. Determine a preset first field from the output fields.
[0105] Combined with the scenario example, define the function def compare_excel_files, call the function with path1, path2, path3 and the name of the compared column as parameters, and compare the data in the first file to be compared with the data in the second file to be compared, where the name of the compared column is the output field in the file. You can select the preset first field from multiple output fields in the file, for example, you can determine the amount field as the first field.
[0106] S1002: Determine the remaining output fields except the first field as conditional columns.
[0107] Combined with the scenario example, call the pandas.read_excel method to obtain the dataFrame object df1 of the first file to be compared and the dataFrame object df2 of the second file to be compared. Determine the columns corresponding to the output fields other than the amount field as conditional columns. First, call the DataFrame.columns method to compare the number of columns of the conditional columns in df1 and df2 for preliminary investigation, and prompt if the number of columns is inconsistent. If the number of columns of the conditional column for withdrawal in the first file to be compared is equal to that of the second file to be compared, you can continue with the subsequent verification. If they are not equal, it can be determined that the first file to be compared is not equal to the second file to be compared.
[0108] S1003: Based on the principle of consistency of condition columns, merge the data in the first file to be compared and the data in the second file to be compared to obtain corresponding multiple union data.
[0109] Combined with the scenario example, except for the amount column, the fields corresponding to other condition columns are kept consistent, and the first file to be compared is merged with the second file to be compared. Specifically, the pandas.merge method can be called to control the on parameter to be the compare_columns object to merge df1 and df2 according to the principle of consistent condition column values, and the how parameter value can be controlled to be 'outer' to let merged1 take the union data of df1 and df2. Fig.11 Schematic diagram of the union data for the example.
[0110] S1004: Determine the file to be compared to which each piece of union data belongs.
[0111] Combined with scenario examples, such as Fig.11As shown, five union data are included, including a column of merge data in addition to the original columns of df1 and df2. The merge data indicates whether the data belongs only to the first file to be compared, only to the second file to be compared, or to both files to be compared.
[0112] S1005: If the union data belongs to both the first file to be compared and the second file to be compared, add a first mark to the union data.
[0113] Combined with the scene example, combined with Fig.11 ,exist Fig.11 In the example, the first union data and the second union data belong to two files to be compared at the same time, so the first union data and the second union data can be marked as the first mark of "both".
[0114] S1006: If the union data only belongs to the first file to be compared, then add a second mark to the union data.
[0115] Combined with the scene example, combined with Fig.11 ,exist Fig.11 In the example, the third and fourth union data only belong to the first file to be compared, so the third and fourth union data can be marked as the second mark of "left noly".
[0116] S1007: If the union data only belongs to the second file to be compared, then a third mark is added to the union data.
[0117] Combined with the scene example, combined with Fig.11 ,exist Fig.11 In the example, the fifth piece of union data only belongs to the second file to be compared, so the fifth piece of union data can be marked as the third mark of "right noly".
[0118] S1008. For the union data marked with the first mark, determine whether the first target value corresponding to the first field in the first file to be compared is equal to the second target value corresponding to the first field in the second file to be compared.
[0119] Combined with the scenario example, for the first union data and the second union data marked with the first mark and the second mark, it means that except for the amount field of the first field, the first target value corresponding to each output field in the first file to be compared is equal to the second target value corresponding to each output field in the second file to be compared, so next we can determine whether the first target value corresponding to the amount field of each union data is equal to the second target value.
[0120] Taking the first union data as an example, the first target value corresponding to the first file to be compared is 1.00, and the second target value corresponding to the second file to be compared is also 1.00, so the union data is completely equal in the first file to be compared and the second file to be compared. However, in the second union data, the first target value corresponding to the first file to be compared is 2.00, and the second target value corresponding to the second file to be compared is also 2.98, so the union data is not equal in the first file to be compared and the second file to be compared.
[0121] In summary, if the mark of each piece of union data is the first mark, and the first target value and the second target value of the amount column in each piece of union data are also equal, then it is determined that the first file to be compared and the second file to be compared are completely equal, and the data before and after the merger of the institutions can be output to be consistent, that is, a verification result without abnormalities. On the contrary, if there is at least one piece of union data whose mark is not the first mark, or the mark of each piece of union data is the first mark, but there is at least one piece of union data whose first target value and the second target value of the amount column are not equal, then the verification result of the inconsistent data before and after the merger of the institutions can be output, that is, an abnormal verification result, and an abnormal result file can be output at the same time. Based on the method provided in this example, the first file to be compared and the second file to be compared can be completely compared to improve the correctness of the verification result.
[0122] Optional, Fig.12 Schematic diagram of the process of the data verification method based on software robot provided in this application Figure 4 ,like Fig.12 In S603, the determining of the abnormal result file includes:
[0123] S1201. Write each added union data marked as the first mark into the first file, write each added union data marked as the second mark into the second file, and write each added union data marked as the third mark into the third file.
[0124] In combination with the scenario example, for the union data with the first mark added, a new difference amount column is added, that is, the difference between the first target value of the amount in the first file to be compared and the second target value of the amount in the second file to be compared, and recorded in the first file. Fig.13 The first file diagram of the example is as follows: Fig.13 As shown in the figure, for the two union data with the first mark added, the difference amount columns are 0 and -0.98 respectively. The union data with the second mark added is combined with the amount and written into the second file. Fig.14 The second file is a schematic diagram of the example. The union data with the third tag added is combined with the amount and written into the third file. Fig.15 The third file diagram is an example.
[0125] S1202: Construct the first file, the second file, and the third file into the abnormal result file.
[0126] In combination with the scenario example, the first file, the second file and the third file are packaged into an Excel file, and the packaged Excel file is determined as the abnormal result file. The abnormal result file can be named using the organization codes of the first organization and the second organization.
[0127] Based on the method provided in this example, the purpose of obtaining an abnormal result file can be achieved.
[0128] Optionally, the method further includes:
[0129] The acquired first historical data and second historical data are saved locally.
[0130] In combination with the scenario example, a folder may be created locally, and the first historical data and the second historical data may be saved in the created folder, so as to save the first historical data and the second historical data locally.
[0131] Optional, Fig.16 Schematic diagram of the process of the data verification method based on software robot provided in this application Figure 5 ,like Fig.16 The step of saving the acquired first historical data and second historical data locally includes:
[0132] S1601. Determine a first folder corresponding to the first institution and a second folder corresponding to the second institution.
[0133] In combination with the scenario example, folders may be created locally, one folder for each organization. For example, a first folder corresponding to the first organization and a second folder corresponding to the second organization may be created locally.
[0134] S1602: Save the first historical data to the first folder, and save the second historical data to the second folder.
[0135] In combination with the scenario example, the first historical data can be saved to a first folder, and the second historical data can be saved to a second folder, so that the first historical data and the second historical data can be saved locally.
[0136] Optional, Fig.17 Schematic diagram of the process of the data verification method based on software robot provided in this application Figure 6 ,like Fig.17 Said S1601 includes:
[0137] S1701. Determine the code, general ledger account, start download time and end download time corresponding to the first institution, and name the local preset folder based on the code, general ledger account, start download time and end download time corresponding to the first institution to obtain a first folder.
[0138] Combined with the scenario example, for example, the code corresponding to the first institution is 1236, the general ledger account is 6031-S2, the start download time and the end download time can be a four-digit year and a three-digit month. For example, the start download time is 2023001 and the end download time is 2023009, then the first folder can be named "2023001-2023009-1236-6031-S2".
[0139] S1702. Determine the code, general ledger account, start download time and end download time corresponding to the second institution, and name the local preset folder based on the code, general ledger account, start download time and end download time corresponding to the second institution to obtain a second folder.
[0140] Combined with the scenario example, for example, the code corresponding to the second institution is 1235, the general ledger account is 6031-S2, the start download time and the end download time can be a four-digit year and a three-digit month. For example, the start download time is 2023010 and the end download time is 2023010, then the second folder can be named "2023010-2023010-1235-6031-S2".
[0141] Based on the method provided in this example, the creation of the first folder and the second folder can be completed.
[0142] The present application can automatically verify the first comparison file and the second comparison file through a software robot, which can speed up the verification efficiency and shorten the verification time.
[0143] Fig.18 A schematic diagram of the structure of the data verification device based on the software robot provided in this application, such as Fig.18 As shown, the device is applied to a computing device, including:
[0144] A determination module 181, configured to determine at least one restriction condition;
[0145] An acquisition module 182, configured to acquire first historical data corresponding to the first institution and second historical data corresponding to the second institution based on the restriction condition, wherein the first historical data is data corresponding to the first institution before the merger, and the second historical data is data corresponding to the second institution after the merger;
[0146] The determination module 181 is further used to determine at least one output field;
[0147] The determination module 181 is further configured to determine a first target value corresponding to each output field in the first historical data, and obtain a first file to be compared based on each first target value;
[0148] The determination module 181 is further configured to determine a second target value corresponding to each output field in the second historical data, and obtain a second file to be compared based on each second target value;
[0149] The processing module 183 is used to automatically verify the first file to be compared and the second file to be compared based on a software robot to output a verification result.
[0150] The data verification device based on software robot provided in this embodiment can execute the method provided in the above method embodiment. Its implementation principle and technical effect are similar, and this embodiment will not be described in detail here.
[0151] Fig.19 This is a schematic diagram of the structure of the electronic device provided in this application. Fig.19 As shown, the electronic device 50 provided in this embodiment includes: at least one processor 501 and a memory 502. Optionally, the device 50 also includes a communication component 503. The processor 501, the memory 502 and the communication component 503 are connected via a bus.
[0152] In a specific implementation process, at least one processor 501 executes the computer-executable instructions stored in the memory 502, so that at least one processor 501 executes the above method.
[0153] The specific implementation process of the processor 501 can be found in the above method embodiment, and its implementation principle and technical effect are similar, so this embodiment will not be repeated here.
[0154] In the above embodiments, it should be understood that the processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), etc. A general-purpose processor may be a microprocessor or any conventional processor, etc. The steps of the method disclosed in the invention may be directly implemented as being executed by a hardware processor, or may be executed by a combination of hardware and software modules in the processor.
[0155] The memory may include a high-speed memory (Random Access Memory, referred to as RAM), and may also include a non-volatile memory (NVM), such as at least one disk storage.
[0156] The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, the bus in the drawings of this application is not limited to only one bus or one type of bus.
[0157] The present application also provides a computer program product, including a computer program, which implements the above method when executed by a processor.
[0158] The present application also provides a computer-readable storage medium, in which computer-executable instructions are stored. When a processor executes the computer-executable instructions, the above method is implemented.
[0159] The above-mentioned readable storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk. The readable storage medium can be any available medium that can be accessed by a general or special-purpose computer.
[0160] An exemplary readable storage medium is coupled to a processor so that the processor can read information from the readable storage medium and write information to the readable storage medium. Of course, the readable storage medium can also be a component of the processor. The processor and the readable storage medium can be located in an application specific integrated circuit (Application Specific Integrated Circuits, referred to as ASIC). Of course, the processor and the readable storage medium can also exist in the device as discrete components.
[0161] The division of units is only a logical function division, and there may be other divisions in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interface, device or unit, which can be electrical, mechanical or other forms.
[0162] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0163] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0164] If the function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods of each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk, etc., various media that can store program codes.
[0165] Those skilled in the art can understand that all or part of the steps of implementing the above-mentioned method embodiments can be completed by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When the program is executed, the steps of the above-mentioned method embodiments are executed; and the aforementioned storage medium includes: ROM, RAM, disk or optical disk and other media that can store program codes.
[0166] Finally, it should be noted that those skilled in the art will readily conceive of other embodiments of the present invention after considering the specification and practicing the invention disclosed herein. The present invention is intended to cover any variations, uses or adaptations of the present invention, which follow the general principles of the present invention and include common knowledge or customary technical means in the art not disclosed by the present invention, are not limited to the precise structure described above and shown in the drawings, and may be modified and changed in various ways without departing from the scope thereof. The scope of the present invention is limited only by the appended claims.
Claims
1. A data verification method based on a software robot, characterized in that: The method is applied to a computing device, comprising: identifying at least one constraint; Acquire first historical data corresponding to the first institution and second historical data corresponding to the second institution based on the restriction condition, wherein the first historical data is data corresponding to the first institution before the merger, and the second historical data is data corresponding to the second institution after the merger; determining at least one output field; Determine a first target value corresponding to each output field in the first historical data, and obtain a first file to be compared based on each first target value; Determine a second target value corresponding to each output field in the second historical data, and obtain a second file to be compared based on each second target value; The first file to be compared and the second file to be compared are automatically verified based on a software robot to output a verification result.
2. The method according to claim 1, characterized in that The automatically verifying the first file to be compared and the second file to be compared based on the software robot to output a verification result includes: Automatically verifying in sequence based on a software robot whether a first target value corresponding to each output field in the first file to be compared is equal to a second target value corresponding to each output field in the second file to be compared; If the first target value corresponding to each output field in the first file to be compared is equal to the second target value corresponding to each output field in the second file to be compared, then output a verification result without abnormality; If the first target value corresponding to at least one output field in the first file to be compared is not equal to the corresponding second target value in the second file to be compared, an abnormal result file is determined, and the abnormal verification result and the abnormal result file are output.
3. The method according to claim 2, characterized in that Automatically checking in sequence based on a software robot whether a first target value corresponding to each output field in the first file to be compared is equal to a second target value corresponding to each output field in the second file to be compared, including: Determine a preset first field from the output fields; Determine the remaining output fields except the first field as conditional columns; Based on the principle of consistency of condition columns, the data in the first file to be compared and the data in the second file to be compared are merged to obtain corresponding multiple pieces of union data; Determine the file to be compared to which each piece of union data belongs; If the union data belongs to both the first file to be compared and the second file to be compared, adding a first mark to the union data; If the union data only belongs to the first file to be compared, adding a second mark to the union data; If the union data only belongs to the second file to be compared, adding a third mark to the union data; For the union data marked with the first mark, it is determined whether the first target value corresponding to the first field in the first file to be compared is equal to the second target value corresponding to the first field in the second file to be compared.
4. The method according to claim 3, characterized in that The abnormal result file is determined to include: Write each added union data marked as the first mark into the first file, write each added union data marked as the second mark into the second file, and write each added union data marked as the third mark into the third file; The first file, the second file and the third file are constructed as the abnormal result file.
5. The method according to any one of claims 1 to 4, characterized in that: The method further comprises: The acquired first historical data and second historical data are saved locally.
6. The method according to claim 5, characterized in that The step of saving the acquired first historical data and second historical data locally includes: Determine a first folder corresponding to the first institution, and a second folder corresponding to the second institution; The first historical data is saved in the first folder, and the second historical data is saved in a second folder.
7. The method according to claim 6, characterized in that The determining a first folder corresponding to the first institution and a second folder corresponding to the second institution includes: Determine the code, general ledger account, start download time and end download time corresponding to the first institution, and name the locally preset folder based on the code, general ledger account, start download time and end download time corresponding to the first institution to obtain a first folder; Determine the code, general ledger account, start download time and end download time corresponding to the second institution, and name the locally preset folder based on the code, general ledger account, start download time and end download time corresponding to the second institution to obtain a second folder.
8. A data verification device based on a software robot, characterized in that: The device is applied to a computing device, comprising: A determination module, used to determine at least one constraint condition; an acquisition module, configured to acquire first historical data corresponding to the first institution and second historical data corresponding to the second institution based on the restriction condition, wherein the first historical data is data corresponding to the first institution before the merger, and the second historical data is data corresponding to the second institution after the merger; The determination module is further used to determine at least one output field; The determination module is further used to determine a first target value corresponding to each output field in the first historical data, and obtain a first file to be compared based on each first target value; The determination module is further used to determine a second target value corresponding to each output field in the second historical data, and obtain a second file to be compared based on each second target value; The processing module is used to automatically verify the first file to be compared and the second file to be compared based on a software robot to output a verification result.
9. A computer device, characterized in that: include: Memory, processor; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory, so that the processor performs the method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, which are used to implement the method according to any one of claims 1 to 7 when executed by a processor.
Citation Information
Patent Citations
RPA process automatic construction method and system based on data driving
CN113535277A
Data verification methods, data verification systems, electronic devices and storage media
CN114936227A
Data verification method and device, computer equipment and storage medium
CN116737708A
Heterogenous data verification method and device, electronic equipment and storage medium
CN117725069A
File comparison method and device, computer equipment and storage medium
CN117933219A