Data checking method and device, electronic equipment, medium and program product
By using the end-to-end stream number to identify each transaction at the beginning and end of the transaction, the problem of high data verification cost in the long and complex link scenarios is solved, and efficient and accurate end-to-end data verification is achieved.
Patent Information
- Application Number
- CN202510090100.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-20
- Publication Date
- 2025-05-16
AI Technical Summary
In scenarios where the link is long and complex, the data association keys across multiple nodes cannot be uniformly aligned, resulting in high cost and low efficiency of end-to-end data verification.
By identifying each transaction between the beginning and end of the transaction, the end-to-end data verification process is simplified and complexity and cost are reduced.
Improve the accuracy, efficiency and adaptability of data verification, and reduce the complexity and cost of end-to-end data verification.
Smart Images

Figure CN120013535A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a data verification method, device, electronic device, medium and program product. Background Art
[0002] Data verification is a key and necessary means to ensure the accuracy of transactions. According to the verification time, it can be divided into minute verification, hourly verification, daily verification, etc.; according to the verification form, it can be divided into point-to-point verification, end-to-end verification, etc.
[0003] At present, the guarantee of data verification is more inclined to upstream and downstream point-to-point verification. However, in scenarios with long and complex links, the cost of implementing end-to-end verification is huge because the data association keys cannot be uniformly aligned after crossing multiple nodes and the data format has also changed. Summary of the invention
[0004] The embodiments of this specification provide a data verification method, device, electronic device, medium and program product, which can avoid going deep into the transaction technology link to establish a complex end-to-end association relationship, simplify the end-to-end data verification process, reduce the complexity and cost of end-to-end data verification, and improve the accuracy, efficiency and adaptability of data verification. The above technical solution is as follows:
[0005] In a first aspect, an embodiment of the present specification provides a data verification method, comprising:
[0006] Acquire a first historical transaction data set corresponding to a transaction start end and a second historical transaction data set corresponding to a transaction end end; the first historical transaction data set includes at least one first historical transaction data and a terminal serial number corresponding to the first historical transaction data; the second historical transaction data set includes second historical transaction data generated by the transaction end end based on the first historical transaction data and a terminal serial number of the first historical transaction data; the terminal serial number is used to identify each transaction between the transaction start end and the transaction end end;
[0007] Based on the terminal serial number, data verification is performed on the first historical transaction data set and the second historical transaction data set to obtain a target verification result.
[0008] In a second aspect, an embodiment of the present specification provides a data verification device, the device comprising:
[0009] A data acquisition module, used to acquire a first historical transaction data set corresponding to a transaction start end and a second historical transaction data set corresponding to a transaction end end; the first historical transaction data set includes at least one first historical transaction data and a terminal serial number corresponding to the first historical transaction data; the second historical transaction data set includes second historical transaction data generated by the transaction end end based on the first historical transaction data and a terminal serial number of the first historical transaction data; the terminal serial number is used to identify each transaction between the transaction start end and the transaction end end;
[0010] The data verification module is used to perform data verification on the first historical transaction data set and the second historical transaction data set based on the terminal serial number to obtain a target verification result.
[0011] In a third aspect, an embodiment of this specification provides an electronic device, including: a processor and a memory;
[0012] The processor is connected to the memory;
[0013] The above-mentioned memory is used to store executable program code;
[0014] The processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the method provided by the first aspect of the embodiment of this specification or any possible implementation of the first aspect.
[0015] In a fourth aspect, an embodiment of the present specification provides a computer storage medium, wherein the computer storage medium stores a plurality of instructions, wherein the instructions are suitable for being loaded by a processor and executing the method provided by the first aspect of the embodiment of the present specification or any possible implementation of the first aspect.
[0016] In a fifth aspect, an embodiment of the present specification provides a computer program product comprising instructions, which, when the above-mentioned computer program product runs on a computer or a processor, enables the above-mentioned computer or the above-mentioned processor to execute the data verification method provided by the first aspect of the embodiment of the present specification or any possible implementation method of the first aspect.
[0017] In the embodiments of the present specification, on the one hand, by identifying each transaction between the transaction start end and the transaction end end through the end serial number, a certain association can be established for the data transactions at both ends, so that the data at both ends can be aligned efficiently and accurately; on the other hand, end-to-end data verification based on the end serial number can avoid in-depth transaction technology links to establish complex end-to-end association relationships, simplify the end-to-end data verification process, reduce the complexity and cost of end-to-end data verification, and improve the accuracy, efficiency and adaptability of data verification. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] In order to more clearly illustrate the technical solutions in the embodiments of this specification, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0019] Figure 1 A schematic diagram of the implementation process of data verification provided in the relevant technology;
[0020] Figure 2 A schematic diagram of the architecture of a data checking system provided as an exemplary embodiment of this specification;
[0021] Figure 3 A flowchart of a data verification method provided by an exemplary embodiment of this specification;
[0022] Figure 4 A schematic diagram of a data verification implementation process provided by an exemplary embodiment of this specification;
[0023] Figure 5 A schematic diagram of an implementation flow of an end-to-end transaction provided as an exemplary embodiment of this specification;
[0024] Figure 6 A schematic diagram of a target end serial number generation process provided by an exemplary embodiment of this specification;
[0025] Figure 7 A schematic diagram of a network architecture for generating a terminal serial number provided by an exemplary embodiment of this specification;
[0026] Figure 8 A schematic diagram of the structure of a data checking device provided as an exemplary embodiment of this specification;
[0027] Fig. 9 The present invention is a schematic diagram of the structure of an electronic device provided by an exemplary embodiment of the present invention. DETAILED DESCRIPTION
[0028] The technical solutions in the embodiments of this specification will be described clearly and completely below in conjunction with the drawings in the embodiments of this specification.
[0029] The terms "first", "second", "third", etc. in this specification and claims and the above drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units that are not listed, or may optionally include other steps or units inherent to these processes, methods, products or devices.
[0030] It should be noted that the information (including but not limited to user device information, user personal information, etc.), data (including but not limited to data used for analysis, stored data, displayed data, etc.) and signals involved in the embodiments of this specification are all authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions. For example, the first historical transaction data set and the second historical transaction data set involved in this specification are all obtained with full authorization.
[0031] Related data verification methods generally require in-depth technical links, establishing associations between upstream and downstream, and connecting both ends to implement data verification. Figure 1 In the transaction link shown, a transaction spans three entities. The transaction start end, as the transaction lead entity, initiates a transaction request, which passes through multiple intermediate nodes (intermediate node A, intermediate node B, and intermediate node C), and finally reaches the transaction end end to perform the corresponding transaction action. In this link, the transaction attributes are only perceived at the transaction start end. When the data channel reaches the transaction end end, these transaction attributes may have faded or completely lost, and only the numerical attributes of the transaction remain. For example, the transaction number corresponding to the transaction request at the transaction start end is 01. When the transaction request reaches intermediate node A and is initiated by intermediate node B to intermediate node B, its transaction number may be 02 obtained after the intermediate node A converts the data according to its internal data structure and data standard; and so on, when the transaction request reaches the transaction end end, its corresponding transaction number may have been converted into a transaction number 04 that is completely different from the original transaction number. Moreover, the systems and data conversion rules adopted by multiple intermediate nodes may be different. Therefore, when performing data verification, it is impossible to directly know the attributes of the transaction through the transaction number at the transaction end end. This leads to the inability to unify the data delineation logic at both ends and the difficulty in aligning data sets. That is, from the start to the end of the transaction, the original transaction number is gradually lost during the transmission process, and the data at both ends cannot be directly associated.
[0032] Therefore, not only do relevant data verification methods often only support one-way data verification, but in reconciliation scenarios, unilateral multiple-account and under-account problems cannot be discovered, and there are major logical loopholes in transactions. In addition, the data relationships established through pairwise associations in relevant technologies are subject to the complexity of the technical chain. The more complex the chain and the more nodes there are, the greater the cost of establishing the association relationship. Once the intermediate nodes change, the association relationship also needs to be maintained synchronously. Data verification is difficult to advance efficiently, and the deployment and implementation costs of data verification are also high, and the subsequent maintenance costs are huge.
[0033] Based on this, the embodiment of this specification provides a data verification method, which identifies each transaction between the transaction start end and the transaction end end through the end serial number, establishes a certain association between the data transactions at both ends, so that the data at both ends can be efficiently and accurately aligned, and performs end-to-end data verification based on the end serial number, avoiding in-depth transaction technology links to establish complex end-to-end association relationships, simplifying the end-to-end data verification process, reducing the complexity and cost of end-to-end data verification, and improving the accuracy, efficiency and adaptability of data verification.
[0034] Please refer to the following Figure 2 , Figure 2 The following is a schematic diagram of the architecture of a data verification system provided by an exemplary embodiment of this specification. Figure 2 As shown, the data checking system may include: a transaction start end 210, a transaction end end 220 and a data checking end 230. Among them:
[0035] The transaction initiation end 210 may be the initiation end of the transaction process, that is, the place where the transaction activity begins, and may specifically include one or more terminals or servers that can initiate transactions. A transaction platform may be set up in the transaction initiation end 110 to enable users to input target transaction operations online, collect initial data required for transactions, such as customer information, order details, payment information, etc., generate a unique transaction end serial number, initiate transaction requests, and other functions. The transaction initiation end 210 may establish a data relationship with the network, and establish a data connection relationship with the data verification end 230 through the network, such as sending a first historical transaction data set, a data verification instruction, and receiving a target data verification result corresponding to the data verification instruction. Among them, the transaction initiation end 210 may be, but is not limited to, a mobile phone, a tablet computer, a laptop computer, or a server corresponding to the transaction platform installed with a transaction platform.
[0036] The transaction end terminal 220 may be the end terminal of the transaction process, such as but not limited to the payment institution terminal that responds to the transaction request. The transaction end terminal 220 and the transaction start terminal 210 above are traded through at least one intermediate node. The transaction end terminal 220 may establish a data relationship with the network, and establish a data connection relationship with the data verification terminal 230 through the network, such as sending a second historical transaction data set, receiving a target data verification result corresponding to a data verification instruction, etc. The transaction end terminal 220 may be but not limited to a mobile phone, tablet computer, laptop computer, server, or other device corresponding to the subject participating in the transaction.
[0037] The data verification end 230 may be a terminal or server that can provide a variety of data verification services. Specifically, the first historical transaction data set corresponding to the transaction initiation end 210 and the second historical transaction data set corresponding to the transaction termination end 220 may be obtained first. The first historical transaction data set includes at least one first historical transaction data and the terminal serial number corresponding to the first historical transaction data. The second historical transaction data set includes the second historical transaction data generated by the transaction termination end based on the first historical transaction data and the terminal serial number of the first historical transaction data. The terminal serial number is used to identify each transaction between the transaction initiation end and the transaction termination end. Then, based on the terminal serial number, the first historical transaction data set and the second historical transaction data set are data verified to obtain the target verification result. The data verification end 230 may also output the target data verification result to the transaction initiation end 210 or the transaction termination end 220, etc. The server may be, but is not limited to, a hardware server, a virtual server, a cloud server, etc.
[0038] It can be understood that the above-mentioned data verification process is not limited to being executed by the above-mentioned data verification terminal 230, but can also be executed by the data verification module in the above-mentioned transaction starting terminal 210, that is, the above-mentioned data verification terminal 230 and the above-mentioned transaction starting terminal 210 can also belong to the same terminal. The embodiments of this specification do not make specific limitations on this. The following embodiments are all explained by taking the data verification terminal 230 executing the above-mentioned data verification as an example.
[0039] The network may be a medium providing a communication link between the transaction initiation end 210 and the data verification end 230, and between the transaction termination end 220 and the data verification end 230, or may be the Internet including network devices and transmission media, but is not limited thereto. The transmission media may be a wired link, such as but not limited to coaxial cable, optical fiber, and digital subscriber line (DSL), or a wireless link, such as but not limited to wireless fidelity (WIFI), Bluetooth, and mobile device network.
[0040] Understandably, Figure 2The number of transaction initiators 210, transaction terminating terminals 220, and data terminating terminals 230 in the data terminating system shown is only an example. In a specific implementation, the data terminating system may include any number of transaction initiators 210, transaction terminating terminals 220, and data terminating terminals 230. This specification embodiment does not specifically limit this. For example, but not limited to, the transaction initiator 210 may be a transaction initiator cluster composed of multiple transaction initiators, and the transaction terminating terminal 220 may be a transaction terminating cluster composed of multiple transaction terminating terminals.
[0041] Next, combine Figure 1 , introduces the data verification method provided by the embodiments of this specification. For details, please refer to Figure 2 , which is a flow chart of a data verification method provided by an exemplary embodiment of this specification. Figure 2 As shown, the data verification method includes the following steps:
[0042] S302, obtaining a first historical transaction data set corresponding to the transaction starting end and a second historical transaction data set corresponding to the transaction ending end, wherein the first historical transaction data set includes at least one first historical transaction data and an end serial number corresponding to the first historical transaction data, and the second historical transaction data set includes second historical transaction data generated by the transaction ending end based on the first historical transaction data and an end serial number of the first historical transaction data.
[0043] Specifically, the terminal serial number is used to identify each transaction between the transaction start end and the transaction end end, and is globally unique, establishing a direct association between the data at both ends without the need to go deep into the technical link for complex association operations. By obtaining the first historical transaction data set and the second historical transaction data set containing the terminal serial number, a certain technical support is provided for the data delineation required in the data verification process.
[0044] Furthermore, the terminal serial number is generated by the transaction initiation end according to the preset rules based on the first historical transaction data, so as to ensure the relevance of the terminal serial number with the specific transaction data; and the terminal serial number is transparently transmitted to the transaction termination end through at least one intermediate node, and is associated and stored with the second historical transaction data generated based on the corresponding first historical transaction data in the transaction termination end, so as to establish the corresponding relationship between the transaction initiation end and the transaction termination end data. In the transparent transmission process of the intermediate node, a transparent transmission method can be adopted, that is, the intermediate node does not modify or process the terminal serial number in any way, and is only responsible for transmitting it from the transaction initiation end to the transaction termination end, thereby ensuring the continuity of the terminal serial number in the entire transaction process, thereby maximizing the consistency and traceability of the terminal serial number. The first historical transaction data may include, for example but not limited to, the transaction request amount initiated by the transaction initiation end, and the second historical transaction data is the historical transaction response data generated by the transaction termination end based on the historical transaction request corresponding to the first historical transaction data carrying the terminal serial number, for example but not limited to, including the transaction amount actually transferred in or out by the transaction termination end, which can be specifically set according to the actual data verification scenario, and the embodiments of this specification are not limited to this.
[0045] Related data verification methods usually require data to be saved at each intermediate node and verified step by step, which not only increases the storage and processing costs, but also easily leads to verification difficulties due to inconsistent data in the intermediate links. However, the embodiment of this specification directly establishes the association between the transaction start end and the transaction end end through the end serial number, bypassing the complexity of the intermediate links, simplifying the verification process, and reducing the possible error screening and matching introduced by the intermediate links, thereby improving the accuracy and efficiency of data verification.
[0046] Optionally, before obtaining the first historical transaction data set corresponding to the transaction initiation end and the second historical transaction data set corresponding to the transaction termination end in S302, a data verification instruction may also be obtained, such as but not limited to receiving a data verification operation input by a user through a user interface and generating a corresponding data verification instruction based on the data verification operation, or automatically generating a data verification instruction regularly at a fixed frequency by a system or receiving a data verification instruction sent by the transaction initiation end. The data verification instruction carries specified data verification information. The specified data verification information may include but is not limited to at least one of the following: a specified data verification time period, a specified data verification transaction type, a specified data verification end serial number, a specified data verification index position, and a specified data verification system identifier. The specified data verification time period is used to limit the time range of data verification, the specified data verification transaction type can be used to filter a specific type of transaction that needs to be verified, the specified data verification end serial number can be used to locate a specific transaction that needs to be verified, the specified data verification index position can be used to limit the data storage location that the user wants to verify, and the specified data verification system identifier is used to filter transactions generated by a specific system that needs to be verified.
[0047] After the data verification instruction is obtained, the first historical transaction data set corresponding to the transaction initiation end and the second historical transaction data set corresponding to the transaction termination end can be obtained in response to the data verification instruction based on the designated data verification information carried by the data verification instruction. For example, but not limited to, the corresponding designated byte group number can be generated according to the preset rule for generating the terminal serial number according to the designated data verification information, and the designated position information of the designated byte group number in the terminal serial number can be determined, and then the designated byte group number corresponding to the above-mentioned designated data verification information and the designated position information corresponding to the designated byte group number are sent to the transaction initiation end and the transaction termination end, so that the transaction initiation end obtains the first historical transaction data set corresponding to the terminal serial number whose byte group number of the designated position information is the designated byte group number, and the transaction termination end obtains the second historical transaction data set corresponding to the terminal serial number whose byte group number of the designated position information is the designated byte group number, or directly obtains the first historical transaction data set generated by the transaction initiation end and the second historical transaction data set generated by the transaction termination end within the designated data verification time period, etc.
[0048] In the embodiments of this specification, in response to the data verification instruction, the historical transaction data sets that need to be verified in the transaction start end and the transaction end end are directly obtained according to the specified data verification information. The advantage of this method is its high flexibility and accuracy. The data verification system no longer needs to obtain and process a large amount of potentially irrelevant data, but can accurately locate and extract the required historical transaction data sets. This not only greatly reduces the workload of data preprocessing and improves the efficiency of data verification, but also reduces the verification errors caused by data mismatches extracted from both ends, and can ensure the relevance and integrity of the data obtained at both ends during the data verification process, improve the accuracy of data verification, and reduce the consumption of system resources, laying a solid foundation for subsequent verification work.
[0049] Please continue to refer to Figure 3 ,like Figure 3 As shown, in the above S302, after obtaining the first historical transaction data set corresponding to the transaction start end and the second historical transaction data set corresponding to the transaction end end, the data verification method further includes:
[0050] S304: Based on the terminal serial number, perform data verification on the first historical transaction data set and the second historical transaction data set to obtain a target verification result.
[0051] Specifically, the target verification result can be used to indicate whether the first historical transaction data set and the second historical transaction data set are consistent. If they are inconsistent, the target verification result can also include abnormal transaction information in the first historical transaction data set and the second historical transaction data set, such as but not limited to abnormal historical transaction data, abnormal historical transaction time, abnormal historical transaction type, abnormal historical transaction system, etc.
[0052] In the embodiments of the present specification, on the one hand, by identifying each transaction between the transaction start end and the transaction end end through the end serial number, a certain association can be established for the data transactions at both ends, so that the data at both ends can be aligned efficiently and accurately; on the other hand, end-to-end data verification based on the end serial number can avoid in-depth transaction technology links to establish complex end-to-end association relationships, simplify the end-to-end data verification process, reduce the complexity and cost of end-to-end data verification, and improve the accuracy, efficiency and adaptability of data verification.
[0053] Optionally, the first end serial number in the first historical transaction data set and the second historical transaction data set can be determined first, that is, the end serial number that exists in both the first historical transaction data set and the second historical transaction data set, and the first historical transaction data and the second historical transaction data corresponding to each first end serial number are compared, for example but not limited to verifying whether the historical request amount in the first historical transaction data set is equal to the historical payment amount in the second historical transaction data set, etc., to obtain the initial verification result corresponding to each first end serial number in the first historical transaction data set and the second historical transaction data set; then, determine whether the second end serial number exists in the first historical transaction data set and the second historical transaction data set, that is, the end serial number that only exists in the first historical transaction data set or the second historical transaction data set; if the second end serial number exists, it means that there are historical transaction data in the first historical transaction data set and the second historical transaction data set that cannot be verified and paired, and the target verification result can be determined based on the second end serial number in the first historical transaction data set and the second historical transaction data set and the initial verification results corresponding to the above-mentioned first end serial numbers. If the second end serial number does not exist in the first historical transaction data set and the second historical transaction data set, it means that there is no historical transaction data in the first historical transaction data set and the second historical transaction data set that cannot be checked and matched, and the target verification result can be directly determined according to the initial verification results corresponding to the above-mentioned first end serial numbers.
[0054] Optionally, the above S304, based on the terminal serial number, performs data verification on the first historical transaction data set and the second historical transaction data set to obtain the target verification result. The implementation process may include but is not limited to: establishing an association relationship between the first historical transaction data set and the second historical transaction data set based on the meaning of the bit group corresponding to the above terminal serial number; performing data verification on the first historical transaction data set and the second historical transaction data set based on the above association relationship to obtain the target verification result. First, based on the meaning of the bit group corresponding to the terminal serial number, the terminal serial number of each historical transaction data can be parsed, for example, the terminal serial number is divided into multiple bit groups (fields), each bit group (field) represents specific information, such as but not limited to transaction type, transaction time, transaction system identification, etc., and the key data such as transaction type, transaction time, transaction system identification, etc. contained therein are extracted, so that the transaction attributes that may have been lost can be retained and identified. Then, using the parsed key data, a direct association relationship is established between the first historical transaction data set and the second historical transaction data set, such as but not limited to using a hash table or index structure to quickly establish a corresponding relationship between the first historical transaction data and the second historical transaction data, avoiding the complexity of establishing association relationships layer by layer in related technologies, and greatly improving efficiency. Finally, based on the established association relationship, the first historical transaction data set and the second historical transaction data set are checked for data, such as but not limited to comparing key information such as the transaction amount at both ends, the transaction status at both ends, and the transaction time at both ends to ensure the consistency of the data at both ends. In this way, any mismatched or abnormal transactions can be quickly identified, thereby obtaining accurate target verification results.
[0055] In the embodiments of this specification, the transaction data of the transaction start end and the transaction end end are accurately located and associated through the meaning information carried by different bit groups in the end serial number, and then the first historical transaction data set and the second historical transaction data set are classified and associated according to the bit group meaning of the end serial number, and the two data sets are directly accurately matched and checked by using the established association relationship, which not only solves the problem of transaction attribute loss in end-to-end data verification, but also greatly simplifies the process of data association. The association between the transaction start end and the transaction end end data is directly established through the end serial number, which avoids the complexity of the intermediate links, improves the accuracy, efficiency and flexibility of data verification, and can adapt to different types of transaction scenarios and data structures.
[0056] Alternatively, if Figure 4 As shown, the above S304, based on the terminal serial number, performs data verification on the first historical transaction data set and the second historical transaction data set to obtain the target verification result. The implementation process may include but is not limited to:
[0057] S402: extracting a historical transaction data subset corresponding to at least one transaction type from the first historical transaction data set and the second historical transaction data set based on the terminal serial number.
[0058] Specifically, the end serial number includes multiple bit groups, and different bit groups represent different meanings. The end serial number of each historical transaction data in the first historical transaction data set and the second historical transaction data set can be parsed, and according to the numerical value (bit group number) corresponding to the bit group representing the transaction type in each end serial number, a historical transaction data subset corresponding to at least one transaction type is extracted from the first historical transaction data set and the second historical transaction data set, that is, the bit group numbers representing the transaction type of the corresponding end serial numbers in the first historical transaction data set and the second historical transaction data set are the same as the historical transaction data subset corresponding to the same transaction type. The above-mentioned historical transaction data subset includes the first historical transaction data and the second historical transaction data belonging to the same transaction type. The embodiment of this specification extracts the historical transaction data subset of each transaction type through the end serial number, so as to realize the rapid screening and classification of a large amount of historical transaction data, which not only retains the unique identification function of the end serial number, but also increases the hierarchical nature of data processing. This hierarchical processing method can greatly improve the efficiency of data verification while ensuring accuracy, especially when facing large-scale and multi-type transaction data.
[0059] S404, performing data verification on the first historical transaction data and the second historical transaction data corresponding to the same terminal serial number in each historical transaction data subset to obtain data verification results corresponding to each transaction type.
[0060] Specifically, after the first historical transaction data set and the second historical transaction data set are classified according to the transaction type, the first historical transaction data and the second historical transaction data with the same end serial number in the historical transaction data subset corresponding to each transaction type can also be checked, that is, the same transaction data at both ends of the same transaction type are checked, and the data verification results corresponding to each transaction type are determined according to the verification results of the historical transaction data corresponding to the end serial number. That is, the end serial number is used as a unique identifier to accurately match the transaction data at the transaction start end and the transaction end end, avoiding data confusion or omission, and ensuring the accuracy of data verification.
[0061] S406: Determine a target verification result based on the data verification result corresponding to at least one transaction type.
[0062] Specifically, the data verification results of each transaction type are integrated to determine the final target verification results of the first historical transaction data set and the second historical transaction data set, which can comprehensively reflect the verification status of different transaction types and help to discover potential problems or anomalies. The above-mentioned target verification results may include the total verification results corresponding to the first historical transaction data set and the second historical transaction data set and the data verification results corresponding to each transaction type. The above-mentioned total verification results are used to indicate whether the first transaction total amount corresponding to the first historical transaction data set and the second transaction total amount corresponding to the second historical transaction data set are consistent, and the above-mentioned data verification results corresponding to each transaction type are used to indicate whether the first historical transaction data and the second historical transaction data corresponding to each transaction type are consistent.
[0063] For example, suppose a financial institution needs to check its daily transaction data. The transactions of the institution include deposits, withdrawals, transfers and other transaction types. Its data checking end can first obtain the first historical transaction data set and the second historical transaction data set containing the terminal serial number from the transaction start end and the transaction end end respectively. Then, based on the bit group number representing the transaction type in the terminal serial number (for example, but not limited to the first 4 bits of the terminal serial number), extract the historical transaction data subset of each transaction type. For example, "0001" may represent a deposit transaction, "0002" represents a withdrawal transaction, and so on. Then, the historical transaction data subset of each transaction type can be checked. For each transaction identified by the terminal serial number, the transaction amount, timestamp and other key information of the transaction start end and the transaction end end will be compared. If a mismatch is found, the transaction will be immediately marked as abnormal. Finally, the data checking results of each transaction type are summarized to generate a comprehensive report (target checking result). This report not only contains the overall matching rate of the first historical transaction data set and the second historical transaction data set, but also lists the matching status of each transaction type in detail, as well as specific abnormal transaction information. Through the above methods, financial institutions can quickly and accurately complete the verification of daily transaction data, greatly improving work efficiency while also enhancing the accuracy of data management.
[0064] In the embodiments of this specification, by introducing the transaction type classification based on the terminal serial number, hierarchical processing of data is achieved. By performing data verification by this level and type, not only the efficiency of data verification is improved, but also the accuracy and comprehensiveness of the verification results are enhanced. Compared with the traditional batch verification method, the embodiments of this specification can locate problems more quickly and more accurately reflect the verification status of different transaction types, providing reliable data support for subsequent transaction analysis and troubleshooting. In addition, the embodiments of this specification can also more easily adapt to changes in transaction types. By simply adjusting the parsing rules of the terminal serial number, it can quickly respond to newly added transaction types, and has strong flexibility and scalability.
[0065] In some possible embodiments, in the above S304, after the target verification result is obtained by performing data verification on the first historical transaction data set and the second historical transaction data set based on the terminal serial number, the data verification method may also include, but is not limited to: when the target verification result is that the first transaction total amount corresponding to the first historical transaction data set is inconsistent with the second transaction total amount corresponding to the second historical transaction data set, locating the abnormal transaction information in the first historical transaction data set and the second historical transaction data set based on the terminal serial number. For example, but not limited to, the historical transaction data in the two data sets can be aligned according to the terminal serial number, that is, a list containing all unique terminal serial numbers is created, and it is ensured that each terminal serial number has a corresponding record in the two data sets (if a certain terminal serial number only exists in one data set, it is marked as abnormal). Then, for each terminal serial number, the transaction amount corresponding to the terminal serial number in the two data sets is compared. If the amount is inconsistent, the transaction corresponding to the terminal serial number is marked as an abnormal transaction, and the relevant abnormal transaction information (such as transaction amount, transaction time, transaction type, etc.) is recorded. In addition, the characteristics of abnormal transactions can be further analyzed, such as whether they involve specific transaction types, specific time periods, or specific transaction systems, so as to gain a deeper understanding of the causes of abnormal transactions. Finally, all abnormal transaction information is compiled into a report for subsequent analysis and processing.
[0066] Please refer to the following Figure 5 , Figure 5 The following is a schematic diagram of an implementation flow of an end-to-end transaction provided by an exemplary embodiment of this specification. Figure 5 As shown, the implementation process of the end-to-end transaction may include but is not limited to:
[0067] S502, obtaining first transaction data.
[0068] Specifically, the transaction initiator may, but is not limited to, obtain the transaction operation input by the user through the user interface, and collect first transaction data related to the transaction operation, such as, but not limited to, the transaction amount, transaction value, etc.
[0069] S504: Generate a target terminal serial number based on the first transaction data according to a preset rule.
[0070] Specifically, a unique target terminal serial number can be generated according to the first transaction data and a predefined rule for generating a terminal serial number, and used to identify and track the flow of the transaction in the entire transaction process. For example, but not limited to, a unique string can be directly randomly generated according to a preset length, and used as the target terminal serial number to mark the transaction corresponding to the first transaction data.
[0071] Alternatively, if Figure 6As shown, the implementation process of the above S504, generating the target end serial number based on the first transaction data according to the preset rule, may include but is not limited to:
[0072] S602: Determine at least one target byte group type based on a target transaction type corresponding to the first transaction data.
[0073] Specifically, the target transaction type corresponding to the first transaction data is different, and the corresponding target bit group type constituting the target terminal serial number may also be different. For example, when the target transaction type is a class with a small transaction volume (for example, but not limited to a daily transaction volume of less than 100, 50, etc.), the target bit group type constituting the above target terminal serial number may only include the transaction type class, and when the target transaction type is a class with a large transaction volume (for example, but not limited to a daily transaction volume of more than 10,000, 100,000, etc.), the target bit group type constituting the above target terminal serial number may need to include multiple types such as the transaction type class, the transaction time class, and the transaction system identification class. The target terminal serial number is composed of multiple types of bit group numbers to avoid the problem of duplication of the generated target terminal serial number due to excessive daily or current transaction volume under the target transaction type corresponding to the first transaction data, thereby ensuring the uniqueness of the generated target terminal serial number. At the same time, different terminal serial numbers can be generated in a targeted manner according to different transaction types, so that the generation of terminal serial numbers is more flexible and targeted, so as to flexibly meet the transaction needs of different transaction types.
[0074] It can be understood that for different transaction types, the length of the corresponding end serial number, the bit group type that constitutes the end serial number, and the bit group number length corresponding to each type of bit group can be different or the same. The specific settings can be made according to actual needs, and the embodiments of this specification do not limit this.
[0075] S604: Generate target byte groups corresponding to at least one target byte group type based on the target transaction information corresponding to the first transaction data and at least one target byte group type according to the message interaction transmission specification.
[0076] Specifically, according to the message interaction transmission specification, based on the target transaction information corresponding to the first transaction data and at least one target bit group type, a target bit group corresponding to each target bit group type is generated, which not only ensures that the generated target end serial number conforms to the standard message interaction format, and is convenient for transmission and parsing between different systems, but also classifies and encodes the target transaction information into different bit groups, so that the target end serial number can carry rich transaction information while also having certain encryption characteristics. Even if the transaction end end obtains the end serial number corresponding to the transaction data, it cannot learn from it the specific transaction type corresponding to the transaction, and other operational information of the transaction start end. Different target bit group types correspond to different categories of target transaction information, and the target transaction information includes at least one of the following categories: target transaction type, target transaction timestamp, target transaction data index bit, and target transaction system identifier.
[0077] S606: randomly generate a corresponding target unique serial number for the first transaction data according to the message interaction transmission specification.
[0078] Specifically, according to the message interaction transmission specification, a corresponding target unique serial number is randomly generated for the first transaction data, which not only ensures that the generated end serial number conforms to the standard message interaction format, facilitating transmission and parsing between different systems, but also ensures the uniqueness of each end serial number to prevent duplication.
[0079] It can be understood that the above S606 and S604 can be executed successively or simultaneously, and the embodiments of this specification are not limited to this.
[0080] S608: Compose a target end serial number corresponding to the first transaction data based on the target byte groups and the target unique sequence number corresponding to each of the at least one target byte group types.
[0081] Specifically, the target bit group carrying the target transaction information and the target unique serial number are combined to form the final target end serial number. This combination of encoding the transaction information into the end serial number not only ensures the uniqueness of the end serial number, but also enables it to carry rich transaction information, making the end serial number an effective bridge connecting the transaction start end and the transaction end end, providing convenience for subsequent data verification, transaction tracking and other operations, and improving the accuracy and efficiency of the entire data verification.
[0082] For example, if the target transaction type corresponding to the first transaction data is "personal credit loan", the corresponding target transaction time at the transaction start end is "November 11, 2024 10:30:00", and the transaction start end transaction system identifier is "LOAN001". First, the target byte group type can be determined according to the target transaction type, including the transaction type class, the transaction time class, and the transaction system identifier class. The byte group "01" of the first 2 bytes of the end serial number can be defined to represent the target transaction type, the target transaction time is encoded into a 14-byte byte group to obtain the byte group number "20241111103000", and the transaction system identifier is encoded into a 4-byte group to obtain the byte group number "0001". Next, a 6-byte random unique serial number "123456" is generated. Finally, these byte groups are combined in order to obtain a 26-byte target end serial number "01202411111030000001123456".
[0083] Optionally, in order to ensure that the end serial numbers generated in different systems or applications are unique globally and avoid various problems caused by duplication of end serial numbers, such as data conflicts, order confusion, etc., a dedicated end serial number generation center (such as but not limited to a server, a database, or a distributed system) can be used to uniformly generate and manage all end serial numbers. When the transaction system or application at any transaction initiation end needs to generate a new end serial number, they will send an end serial number generation request to the end serial number generation center to apply for the corresponding end serial number from the end serial number generation center. After receiving the end serial number generation request, the end serial number generation center can respond to the end serial number generation request, generate a corresponding globally unique end serial number according to the preset rules in the above S504, and distribute it to the system or application at the corresponding transaction initiation end, so as to realize the centralized management of the end serial number, simplify the management and maintenance of the end serial number, and improve the maintainability and scalability of the system. The implementation process of the end serial number generation center generating the end serial number is consistent with the implementation process of the above S504, which will not be repeated here.
[0084] Exemplarily, when the system that conducts the transaction at the transaction initiation end is system A, system A will apply to the end serial number generation center for the end serial number corresponding to its current transaction, that is, send the corresponding end serial number generation request, which may, but is not limited to, carry the system identification corresponding to system A, transaction data, etc., so that the end serial number generation center can identify the source of the request. After receiving the end serial number generation request sent by system A, the end serial number generation center can generate a new globally unique end serial number according to the above preset rules based on the internal generation algorithm, and return the unique end serial number to system A at the transaction initiation end. After receiving the end serial number, system A at the transaction initiation end can use it for subsequent transaction processing, such as generating a transaction request based on the end serial number and transaction data. Similarly, when the system that conducts the transaction at the transaction initiation end is system B, it will also apply to the end serial number generation center for the end serial number corresponding to the current transaction, and the application format is similar to that of system A, and the end serial number generation center will generate a new globally unique serial number and return it to system B at the transaction initiation end.
[0085] Please continue to refer to Figure 5 ,like Figure 5 As shown, in the above S504, after the target end serial number is generated according to the preset rule based on the first transaction data, the following steps may also be performed, but are not limited to:
[0086] S506: Generate a target transaction request based on the first transaction data and the target end serial number.
[0087] Specifically, a target transaction request may be constructed according to the first transaction data and the target end serial number. The target transaction request includes the amount or value or information of the specific requested transaction in the first transaction data and the target end serial number corresponding to the transaction.
[0088] S508, sending the target transaction request to the transaction end through at least one intermediate node, so that the transaction end performs the corresponding target transaction action based on the target transaction request to obtain the corresponding second transaction data, and associates the second transaction data with the target end serial number carried by the target transaction request and stores them.
[0089] Specifically, the target transaction request can be sent to an intermediate node. After receiving the target transaction request, the intermediate node forwards it to the next intermediate node until it finally reaches the transaction end. During the forwarding process of the intermediate node, the target end serial number carried by the target transaction request is only transmitted through, and the value is prohibited from changing in the entire link. After receiving the target transaction request, the transaction end will parse it and execute the corresponding target transaction action, such as deduction, delivery, etc., according to the content of the target transaction request. After the transaction end executes the target transaction action, it generates the corresponding second transaction data, such as but not limited to the transaction result, transaction amount, etc., and associates the second transaction data with the target end serial number and stores it in its database, so that the second transaction data corresponding to the transaction can be quickly queried through the target end serial number later.
[0090] S510, after the target transaction request is completed, the first transaction data is associated with the target end serial number and stored.
[0091] Specifically, after the target transaction request is completed, for example, when the transaction end end returns the transaction completion confirmation information, the transaction start end will also associate and store the first transaction data with the target end serial number, so that the first transaction data corresponding to the transaction can be quickly queried through the target end serial number later.
[0092] Please refer to the following Figure 8 , Figure 8 The following is a schematic diagram of a data checking device provided by an exemplary embodiment of this specification. Figure 8 As shown, the data checking device 800 includes:
[0093] The data acquisition module 810 is used to acquire a first historical transaction data set corresponding to a transaction start end and a second historical transaction data set corresponding to a transaction end end; the first historical transaction data set includes at least one first historical transaction data and a terminal serial number corresponding to the first historical transaction data; the second historical transaction data set includes second historical transaction data generated by the transaction end end based on the first historical transaction data and a terminal serial number of the first historical transaction data; the terminal serial number is used to identify each transaction between the transaction start end and the transaction end end;
[0094] The data verification module 820 is used to perform data verification on the first historical transaction data set and the second historical transaction data set based on the terminal serial number to obtain a target verification result.
[0095] In a possible implementation, the terminal serial number is generated by the transaction initiation terminal according to a preset rule based on the first historical transaction data, and is transparently transmitted to the transaction termination terminal through at least one intermediate node, and is associated and stored in the transaction termination terminal with the second historical transaction data generated based on the corresponding first historical transaction data;
[0096] The second historical transaction data is historical transaction response data generated by the transaction termination end based on the first historical transaction data corresponding to the historical transaction request carrying the terminal serial number.
[0097] In a possible implementation, the above method is applied to the above transaction initiator;
[0098] The data acquisition module 810 is further used to: acquire first transaction data; the first transaction data is obtained based on the transaction operation of the user;
[0099] The data checking device 800 further includes:
[0100] A terminal serial number generating module, used to generate a target terminal serial number according to a preset rule based on the first transaction data;
[0101] A transaction request generating module, used for generating a target transaction request based on the first transaction data and the target terminal serial number;
[0102] a sending module, configured to send the target transaction request to the transaction end terminal through at least one intermediate node, so that the transaction end terminal executes a corresponding target transaction action based on the target transaction request to obtain corresponding second transaction data, and associates and stores the second transaction data with the target end serial number carried by the target transaction request;
[0103] The storage module associates and stores the first transaction data with the target terminal serial number after the target transaction request is completed.
[0104] In a possible implementation, the terminal serial number generating module is specifically used to:
[0105] According to the message interaction transmission specification, at least one target bit group type is determined based on the target transaction type corresponding to the above-mentioned first transaction data; based on the target transaction information corresponding to the above-mentioned first transaction data and the above-mentioned at least one target bit group type, a target bit group corresponding to each of the above-mentioned at least one target bit group type is generated; different target bit group types correspond to different target transaction information categories; the above-mentioned target transaction information includes at least one of the following categories: target transaction type, target transaction timestamp, target transaction data index bit, target transaction system identifier; a corresponding target unique serial number is randomly generated for the above-mentioned first transaction data; based on the target bit group corresponding to each of the above-mentioned at least one target bit group type and the above-mentioned target unique serial number, a target end serial number corresponding to the above-mentioned first transaction data is composed.
[0106] In a possible implementation, the data checking device 800 further includes:
[0107] An instruction acquisition module is used to acquire a data verification instruction; the data verification instruction carries specified data verification information; the specified data verification information includes at least one of the following: a specified data verification time period, a specified data verification transaction type, a specified data verification end serial number, a specified data verification index position, and a specified data verification system identifier;
[0108] The data acquisition module 810 is specifically used for:
[0109] In response to the data verification instruction, a first historical transaction data set corresponding to the transaction start end and a second historical transaction data set corresponding to the transaction end end are obtained based on the specified data verification information.
[0110] In a possible implementation, the data checking module 820 includes:
[0111] A relationship establishing unit, configured to establish an association relationship between the first historical transaction data set and the second historical transaction data set based on the meaning of the bit group corresponding to the terminal serial number;
[0112] The first data checking unit is used to perform data checking on the first historical transaction data set and the second historical transaction data set based on the association relationship to obtain a target checking result.
[0113] In a possible implementation, the data checking module 820 includes:
[0114] A data extraction unit, configured to extract, based on the terminal serial number, a subset of historical transaction data corresponding to at least one transaction type from the first historical transaction data set and the second historical transaction data set;
[0115] A second data checking unit is used to check the first historical transaction data and the second historical transaction data corresponding to the same terminal serial number in each of the above historical transaction data subsets to obtain a data checking result corresponding to each transaction type;
[0116] The result determination unit is used to determine the target verification result based on the data verification result corresponding to each of the at least one transaction type.
[0117] In a possible implementation, the data checking device 800 further includes:
[0118] A positioning module is used to locate abnormal transaction information in the first historical transaction data set and the second historical transaction data set based on the terminal serial number when the target verification result is that the first transaction total amount corresponding to the first historical transaction data set is inconsistent with the second transaction total amount corresponding to the second historical transaction data set.
[0119] The division of the modules in the above-mentioned data checking device is only for illustration. In other embodiments, the data checking device can be divided into different modules as needed to complete all or part of the functions of the above-mentioned data checking device. The implementation of each module in the data checking device provided in the embodiments of this specification can be in the form of a computer program. The computer program can be run on a terminal or a server. The program modules constituted by the computer program can be stored in the memory of the terminal or the server. When the computer program is executed by the processor, all or part of the steps of the data checking method described in the embodiments of this specification are implemented.
[0120] See next Fig. 9 , Fig. 9 This is a schematic diagram of the structure of an electronic device provided by an exemplary embodiment of this specification. Fig. 9 As shown, the electronic device 900 may include: at least one processor 910, at least one communication bus 920, a user interface 930, at least one network interface 940, and a memory 950. The communication bus 920 may be used to realize the connection and communication of the above components.
[0121] The user interface 930 may include a display screen (Display) and a camera (Camera). Optionally, the user interface 930 may also include a standard wired interface and a wireless interface.
[0122] The network interface 940 may optionally include a Bluetooth module, a Near Field Communication (NFC) module, a Wireless Fidelity (Wi-Fi) module, and the like.
[0123] Among them, the processor 910 may include one or more processing cores. The processor 910 uses various interfaces and lines to connect various parts within the entire electronic device 900, and executes various functions and processes data of the routing electronic device 900 by running or executing instructions, programs, code sets or instruction sets stored in the memory 950, and calling data stored in the memory 950. Optionally, the processor 910 can be implemented in at least one hardware form of digital signal processing (Digital Signal Processing, DSP), field programmable gate array (Field-Programmable Gate Array, FPGA), and programmable logic array (Programmable Logic Array, PLA). The processor 910 can integrate one or more combinations of a processor (Central Processing Unit, CPU), a graphics processor (Graphics Processing Unit, GPU), and a modem. Among them, the CPU mainly processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing the content to be displayed on the display screen; and the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 910, but may be implemented separately through a chip.
[0124] Among them, the memory 950 may include a random access memory (Random Access Memory, RAM) and may also include a read-only memory (Read-Only Memory, ROM). Optionally, the memory 950 includes a non-transitory computer-readable medium. The memory 950 can be used to store instructions, programs, codes, code sets or instruction sets. The memory 950 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as a data acquisition function, a data verification function, an end serial number generation function, etc.), instructions for implementing the above-mentioned various method embodiments, etc.; the data storage area may store data involved in the above-mentioned various method embodiments, etc. The memory 950 may also be optionally at least one storage device located away from the aforementioned processor 910. As Fig. 9 As shown, the memory 950 as a computer storage medium may include an operating system, a network communication module, a user interface module, and an application program.
[0125] Specifically, the processor 910 can be used to call the application stored in the memory 950, and perform the following operations: obtain a first historical transaction data set corresponding to the transaction starting end and a second historical transaction data set corresponding to the transaction ending end; the above-mentioned first historical transaction data set includes at least one first historical transaction data and an end serial number corresponding to the above-mentioned first historical transaction data; the above-mentioned second historical transaction data set includes the second historical transaction data generated by the above-mentioned transaction ending end based on the above-mentioned first historical transaction data and the end serial number of the above-mentioned first historical transaction data; the above-mentioned end serial number is used to identify each transaction between the above-mentioned transaction starting end and the above-mentioned transaction ending end; based on the above-mentioned end serial number, the above-mentioned first historical transaction data set and the above-mentioned second historical transaction data set are data checked to obtain the target verification result.
[0126] In some possible embodiments, the end serial number is generated by the transaction starting end according to preset rules based on the first historical transaction data, and is transparently transmitted to the transaction ending end through at least one intermediate node, and is associated and stored in the transaction ending end with the second historical transaction data generated based on the corresponding first historical transaction data; the second historical transaction data is the historical transaction response data generated by the transaction ending end based on the historical transaction request corresponding to the first historical transaction data carrying the end serial number.
[0127] In some possible embodiments, the above method is applied to the above transaction starting end; the above processor 910 is also used to execute: obtaining first transaction data; the above first transaction data is obtained based on the user's transaction operation; generating a target end serial number based on the above first transaction data according to a preset rule; generating a target transaction request based on the above first transaction data and the above target end serial number; sending the above target transaction request to the above transaction ending end through at least one intermediate node, so that the above transaction ending end performs a corresponding target transaction action based on the above target transaction request to obtain corresponding second transaction data, and associates and stores the above second transaction data with the above target end serial number carried by the above target transaction request; after the above target transaction request is completed, the above first transaction data is associated and stored with the above target end serial number.
[0128] In some possible embodiments, when the processor 910 executes the above-mentioned generation of the target terminal serial number based on the first transaction data according to the preset rule, it is specifically used to execute:
[0129] Determine at least one target bit group type based on the target transaction type corresponding to the above-mentioned first transaction data; generate target bit groups corresponding to the above-mentioned at least one target bit group type based on the target transaction information corresponding to the above-mentioned first transaction data and the above-mentioned at least one target bit group type according to the message interaction transmission specification; different target bit group types correspond to different target transaction information categories; the above-mentioned target transaction information includes at least one of the following categories: target transaction type, target transaction timestamp, target transaction data index bit, target transaction system identifier; randomly generate a corresponding target unique serial number for the above-mentioned first transaction data according to the above-mentioned message interaction transmission specification; compose a target end serial number corresponding to the above-mentioned first transaction data based on the target bit groups corresponding to the above-mentioned at least one target bit group type and the above-mentioned target unique serial number.
[0130] In some possible embodiments, before the processor 910 executes the above-mentioned acquisition of the first historical transaction data set corresponding to the transaction start end and the second historical transaction data set corresponding to the transaction end end, it is also used to execute: acquiring a data verification instruction; the data verification instruction carries specified data verification information; the specified data verification information includes at least one of the following: a specified data verification time period, a specified data verification transaction type, a specified data verification end serial number, a specified data verification index bit, and a specified data verification system identifier.
[0131] When the processor 910 executes the above-mentioned acquisition of the first historical transaction data set corresponding to the transaction start end and the second historical transaction data set corresponding to the transaction end end, it is specifically used to execute:
[0132] In response to the data verification instruction, a first historical transaction data set corresponding to the transaction start end and a second historical transaction data set corresponding to the transaction end end are obtained based on the specified data verification information.
[0133] In some possible embodiments, when the processor 910 performs the data verification on the first historical transaction data set and the second historical transaction data set based on the end serial number to obtain the target verification result, it is specifically used to execute: establishing an association relationship between the first historical transaction data set and the second historical transaction data set based on the meaning of the bit group corresponding to the end serial number; and performing data verification on the first historical transaction data set and the second historical transaction data set based on the association relationship to obtain the target verification result.
[0134] In some possible embodiments, when the processor 910 performs the data verification of the first historical transaction data set and the second historical transaction data set based on the terminal serial number to obtain the target verification result, it is specifically used to execute: extracting a historical transaction data subset corresponding to at least one transaction type from the first historical transaction data set and the second historical transaction data set based on the terminal serial number; performing data verification on the first historical transaction data and the second historical transaction data corresponding to the same terminal serial number in each of the historical transaction data subsets to obtain the data verification result corresponding to each transaction type; and determining the target verification result based on the data verification result corresponding to each of the at least one transaction type.
[0135] In some possible embodiments, after the processor 910 performs the data verification on the first historical transaction data set and the second historical transaction data set based on the terminal serial number and obtains the target verification result, it is also used to execute: when the target verification result is that the first transaction total amount corresponding to the first historical transaction data set is inconsistent with the second transaction total amount corresponding to the second historical transaction data set, locate the abnormal transaction information in the first historical transaction data set and the second historical transaction data set based on the terminal serial number.
[0136] The embodiments of this specification also provide a computer-readable storage medium, which stores instructions, and when the instructions are executed on a computer or a processor, the computer or the processor executes one or more steps in the above embodiments. If the components of the above data verification device are implemented in the form of software functional units and sold or used as independent products, they can be stored in the above computer-readable storage medium.
[0137] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The above computer program product includes one or more computer instructions. When the above computer program instructions are loaded and executed on a computer, the above process or function according to the embodiment of this specification is generated in whole or in part. The above computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The above computer instructions can be stored in a computer-readable storage medium or transmitted by the above computer-readable storage medium. The above computer instructions can be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (Digital Subscriber Line, DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode. The above computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server, data center, etc. that contains one or more available media integrated. The above-mentioned available media can be magnetic media (for example, floppy disks, hard disks, tapes), optical media (for example, digital versatile discs (DVD)), or semiconductor media (for example, solid state drives (SSD)), etc.
[0138] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program, and the program can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. The aforementioned storage medium includes: ROM, RAM, magnetic disk or optical disk and other media that can store program codes. In the absence of conflict, the technical features in this embodiment and the implementation scheme can be combined arbitrarily.
[0139] The embodiments described above are merely preferred embodiments of this specification and are not intended to limit the scope of this specification. Without departing from the design spirit of this specification, various modifications and improvements made to the technical solutions of this specification by ordinary technicians in this field should fall within the scope of protection determined by the claims.
[0140] The above is a description of a specific embodiment of the specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims and the specification can be performed in an order different from the order in which the embodiments are recorded in the specification and still achieve the desired results. In addition, the processes depicted in the drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
Claims
1. A data verification method, the method comprising: Acquire a first historical transaction data set corresponding to a transaction start end and a second historical transaction data set corresponding to a transaction end end; the first historical transaction data set includes at least one first historical transaction data and a terminal serial number corresponding to the first historical transaction data; the second historical transaction data set includes second historical transaction data generated by the transaction end end based on the first historical transaction data and a terminal serial number of the first historical transaction data; the terminal serial number is used to identify each transaction between the transaction start end and the transaction end end; Based on the terminal serial number, data verification is performed on the first historical transaction data set and the second historical transaction data set to obtain a target verification result.
2. The method according to claim 1, wherein the terminal serial number is generated by the transaction initiation terminal according to a preset rule based on the first historical transaction data, and is transparently transmitted to the transaction termination terminal through at least one intermediate node, and is associated and stored in the transaction termination terminal with the second historical transaction data generated based on the corresponding first historical transaction data; The second historical transaction data is historical transaction response data generated by the transaction end terminal based on the first historical transaction data corresponding to the historical transaction request carrying the terminal serial number.
3. The method according to claim 1, wherein the method is applied to the transaction initiator; the method further comprises: Obtaining first transaction data; The first transaction data is obtained based on the transaction operation of the user; Generate a target terminal serial number based on the first transaction data according to a preset rule; Generate a target transaction request based on the first transaction data and the target end serial number; Sending the target transaction request to the transaction end terminal through at least one intermediate node, so that the transaction end terminal executes a corresponding target transaction action based on the target transaction request to obtain corresponding second transaction data, and associates and stores the second transaction data with the target end serial number carried by the target transaction request; After the target transaction request is completed, the first transaction data is associated with the target end serial number and stored.
4. The method according to claim 3, wherein generating a target terminal serial number based on the first transaction data according to a preset rule comprises: determining at least one target bit group type based on a target transaction type corresponding to the first transaction data; According to the message interaction transmission specification, based on the target transaction information corresponding to the first transaction data and the at least one target bit group type, a target bit group corresponding to each of the at least one target bit group types is generated; different target bit group types correspond to different types of target transaction information; the target transaction information includes at least one of the following categories: target transaction type, target transaction timestamp, target transaction data index bit, and target transaction system identifier; According to the message interaction transmission specification, randomly generate a corresponding target unique serial number for the first transaction data; A target end serial number corresponding to the first transaction data is composed based on the target byte groups corresponding to each of the at least one target byte group types and the target unique sequence number.
5. The method according to claim 1, before obtaining the first historical transaction data set corresponding to the transaction start end and the second historical transaction data set corresponding to the transaction end end, the method further comprises: Get data verification instructions; The data verification instruction carries specified data verification information; The specified data verification information includes at least one of the following: a specified data verification time period, a specified data verification transaction type, a specified data verification end serial number, a specified data verification index position, and a specified data verification system identifier; The obtaining of a first historical transaction data set corresponding to a transaction start end and a second historical transaction data set corresponding to a transaction end end includes: In response to the data verification instruction, a first historical transaction data set corresponding to the transaction start end and a second historical transaction data set corresponding to the transaction end end are obtained based on the specified data verification information.
6. The method according to claim 1, wherein based on the terminal serial number, performing data verification on the first historical transaction data set and the second historical transaction data set to obtain a target verification result comprises: Establishing an association relationship between the first historical transaction data set and the second historical transaction data set based on the meaning of the bit group corresponding to the terminal serial number; Based on the association relationship, data verification is performed on the first historical transaction data set and the second historical transaction data set to obtain a target verification result.
7. The method according to claim 1, wherein based on the terminal serial number, performing data verification on the first historical transaction data set and the second historical transaction data set to obtain a target verification result comprises: Based on the terminal serial number, extracting a historical transaction data subset corresponding to at least one transaction type from the first historical transaction data set and the second historical transaction data set; Performing data verification on the first historical transaction data and the second historical transaction data corresponding to the same terminal serial number in each of the historical transaction data subsets to obtain data verification results corresponding to each transaction type; A target verification result is determined based on the data verification result corresponding to each of the at least one transaction type.
8. The method according to claim 1, wherein after performing data verification on the first historical transaction data set and the second historical transaction data set based on the terminal serial number and obtaining a target verification result, the method further comprises: When the target verification result is that the first transaction total amount corresponding to the first historical transaction data set is inconsistent with the second transaction total amount corresponding to the second historical transaction data set, the abnormal transaction information in the first historical transaction data set and the second historical transaction data set is located based on the terminal serial number.
9. A data checking device, comprising: A data acquisition module, used to acquire a first historical transaction data set corresponding to a transaction start end and a second historical transaction data set corresponding to a transaction end end; the first historical transaction data set includes at least one first historical transaction data and a terminal serial number corresponding to the first historical transaction data; the second historical transaction data set includes second historical transaction data generated by the transaction end end based on the first historical transaction data and the terminal serial number of the first historical transaction data; the terminal serial number is used to identify each transaction between the transaction start end and the transaction end end; The data verification module is used to perform data verification on the first historical transaction data set and the second historical transaction data set based on the terminal serial number to obtain a target verification result.
10. An electronic device comprising: Processor and memory; The processor is connected to the memory; The memory is used to store executable program code; The processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the method according to any one of claims 1 to 8.
11. A computer storage medium storing a plurality of instructions, wherein the instructions are suitable for being loaded by a processor and executing the method steps according to any one of claims 1 to 8.
12. A computer program product comprising instructions, which, when executed on a computer or a processor, enables the computer or the processor to execute the data checking method according to any one of claims 1 to 8.