Data synchronization verification method, system and readable storage medium for bill of materials
By obtaining the operation objects, historical modification moments and operation information in the bill of materials for multi-dimensional verification, the problem of conflicts and incompleteness in data synchronization is solved, ensuring accurate synchronization of data between different systems, and realizing data synchronization. Accuracy and reliability.
Patent Information
- Application Number
- CN202410165202.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-02-05
- Publication Date
- 2024-10-11
- Estimated Expiration
- 2044-02-05
AI Technical Summary
Existing data synchronization technology can easily lead to data conflicts and time inconsistencies leading to synchronization errors when synchronizing between multiple data sources. The data format conversion algorithm is limited and cannot cover all data formats, resulting in incomplete or incorrect data.
By obtaining the operation object, historical modification time and operation information of the data to be verified in the bill of materials, it is judged whether it meets the data conflict, time and integrity verification conditions. If not, a synchronization failure prompt is output and the data synchronization operation is performed. Use hash value comparison to determine information integrity and ensure the accuracy of data synchronization.
It implements multi-dimensional verification of data synchronization to ensure accurate synchronization of data between different systems, avoids data conflicts and incompleteness issues, and improves the accuracy and reliability of data synchronization.
Smart Images

Figure CN117992545B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a data synchronization verification method and system for a bill of materials and a readable storage medium. Background Art
[0002] BOM (Bill of Material) is a list of material data such as various materials, parts, and components required to manufacture a product. In order to reduce the time cost and / or labor cost required in the process of importing material data, in the relevant technical solutions, a third-party data interface is usually set up to synchronize the material data from the PDM (Product Data Management) system to the ERP (Enterprise Resource Planning) system, thereby reducing the time cost and / or labor cost required in the process of data import.
[0003] However, the current data synchronization technology has the following major defects: First, when synchronizing between multiple data sources, some data may have been modified before synchronization, which may cause data conflicts such as read-write conflicts, write-read conflicts, and write-write conflicts, thereby causing data conflicts; Second, during the data synchronization process, due to the different time when the material data is entered between the two systems, the data cannot be correctly synchronized from one system to another during synchronization, resulting in data synchronization errors; Third, the data formats in the data sources in different systems are often different, and the algorithms for data format conversion in data synchronization are limited and cannot cover all data formats on the market. In this case, data synchronization is prone to data errors or incomplete data.
[0004] Application number CN202111297967.7 discloses a data synchronization correction method based on material balance, which records that by correcting the significant measurement-related errors and missing material movement information in the material balance model, it can correct data errors during data synchronization, but does not involve the data conflict dimension and data time dimension for correction, and has the defect of insufficient verification accuracy. Therefore, a multi-dimensional data verification method based on data conflict dimension, data redundancy dimension and data integrity dimension is needed to synchronize the material data of two systems to ensure the accuracy of data verification.
[0005] The above contents are only used to assist in understanding the technical solution of the present invention and do not constitute an admission that the above contents are prior art. Summary of the invention
[0006] The main purpose of the present invention is to provide a data synchronization verification method for a bill of materials, aiming to solve the problem of how to perform multi-dimensional data verification.
[0007] To achieve the above object, the present invention provides a data synchronization verification method for a bill of materials, the data synchronization verification method for a bill of materials comprising:
[0008] Obtain at least one of the data operation object, historical modification time, and historical operation information recorded when the data of the material to be verified in the bill of materials was last updated;
[0009] Determine, according to at least one of the data operation object, the historical modification time and the historical operation information, whether the synchronization status of the material data to be verified satisfies at least one of a preset data conflict verification condition, a data time verification condition and a data integrity verification condition;
[0010] If not satisfied, a synchronization failure prompt is output, and a data synchronization operation is performed on the material data to be verified.
[0011] Optionally, the verification condition includes a data conflict verification condition, a data time verification condition, and a data integrity verification condition, and the step of determining whether the synchronization status of the material data to be verified meets the preset synchronization verification condition according to at least one of the data operation object, the historical modification time, and the historical operation information includes:
[0012] Determine whether the number of the data operation objects is single, if so, determine that the synchronization condition satisfies the data conflict check condition, otherwise, determine that it does not satisfy the condition; and / or,
[0013] Determine whether the historical modification time is after the creation time of the material data to be verified on the preset time axis, if so, determine that the synchronization condition meets the data time verification condition, otherwise, determine that it does not meet the condition; and / or,
[0014] Obtain historical material data to be verified before the material data to be verified executes the historical operation information, determine the information integrity between the historical material data to be verified and the material data to be verified, and when the information integrity is greater than or equal to a preset integrity threshold, determine that the synchronization situation meets the data integrity verification condition, otherwise, determine that it is not satisfied.
[0015] Optionally, the step of determining the information integrity between the historical material data to be verified and the material data to be verified includes:
[0016] Determine the hash value between each data node corresponding to the material data to be verified and the historical material data to be verified;
[0017] The information integrity is determined according to the hash values between the data nodes.
[0018] Optionally, the step of determining the information integrity according to the hash value between each of the data nodes includes:
[0019] Comparing the hash values between the data nodes, if the hash values between the data nodes are the same, increasing the information integrity based on a preset increment; or,
[0020] If the hash values between the data nodes are the same, the information integrity is set to the target information integrity, wherein the target information integrity is greater than or equal to the integrity threshold.
[0021] Optionally, the step of obtaining at least one of a data operation object, a historical modification time, and historical operation information recorded when the data of the material to be verified in the bill of materials was last updated includes at least one of the following:
[0022] Obtain the current time and the operation object ID field in the cache record table associated with the material data to be verified, and determine the operation object ID field closest to the current time in the timestamp of each operation object ID field as the data operation object recorded at the last update;
[0023] Obtain the current time and the timestamps corresponding to the data modification logs in the cache record table associated with the material data to be verified, and determine the timestamp field closest to the current time among the timestamps as the historical modification time recorded during the last update;
[0024] Obtain the current moment and each data modification log in the cache record table associated with the material data to be verified, and determine the operation information field in the data modification log closest to the current moment in the timestamp corresponding to each data modification log as the historical operation information recorded during the last update.
[0025] Optionally, the step of performing a data synchronization operation on the material data to be verified includes at least one of the following:
[0026] If there are multiple data operation objects, obtain the operation authority level of each of the data operation objects, determine the operation priority of the data operation object according to the operation authority level, and perform the data synchronization operation of each of the data operation objects according to the operation priority based on a preset interval duration;
[0027] If the historical modification time is before the creation time of the material data to be verified, performing the data synchronization operation on the material data to be verified;
[0028] If the information integrity between the historical material data to be verified before the material data to be verified executes the historical operation information and the material data to be verified is less than a preset integrity threshold, the data synchronization operation is performed on the material data to be verified.
[0029] Optionally, after the step of determining whether the synchronization status of the material data to be verified satisfies at least one of a preset data conflict verification condition, a data time verification condition, and a data integrity verification condition according to at least one of the data operation object, the historical modification time, and the historical operation information, the step further includes:
[0030] If satisfied, a prompt indicating successful synchronization is output.
[0031] Optionally, after the step of outputting a synchronization failure prompt and performing a data synchronization operation on the material data to be verified, the method further includes:
[0032] At every preset period, return to execute the step of obtaining at least one of the data operation object, the historical modification time and the historical operation information recorded when the data of the material to be verified in the material list was last updated.
[0033] In addition, to achieve the above-mentioned purpose, the present invention also provides a data synchronization verification system for a bill of materials, wherein the data synchronization verification system device for a bill of materials comprises: a memory, a processor, and a data synchronization verification program for a bill of materials stored in the memory and executable on the processor, wherein the data synchronization verification program for the bill of materials implements the steps of the data synchronization verification method for the bill of materials as described above when executed by the processor.
[0034] In addition, to achieve the above-mentioned purpose, the present invention also provides a computer-readable storage medium, on which a data synchronization verification program for a bill of materials is stored. When the data synchronization verification program for the bill of materials is executed by a processor, the steps of the data synchronization verification method for the bill of materials as described above are implemented.
[0035] An embodiment of the present invention provides a data synchronization verification method, system and readable storage medium for a bill of materials. By using a multi-dimensional data verification method based on data conflict dimensions, data redundancy dimensions and data integrity dimensions, the synchronized material data is verified to see whether they are correct, thereby ensuring the accuracy of data synchronization. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] Figure 1 It is a schematic diagram of the architecture of the hardware operating environment of the data synchronization verification system of the bill of materials involved in the embodiment of the present invention;
[0037] Figure 2 A schematic flow chart of a first embodiment of a method for data synchronization verification of a bill of materials of the present invention;
[0038] Figure 3 A schematic flow chart of a second embodiment of a method for data synchronization verification of a bill of materials of the present invention;
[0039] Figure 4 It is a flow chart of a third embodiment of the data synchronization verification method of the bill of materials of the present invention;
[0040] Figure 5 4 is a flow chart of a fourth embodiment of a method for data synchronization and verification of a bill of materials according to the present invention.
[0041] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0042] This application verifies whether the synchronized material data is correct based on the three dimensions of synchronization operation object, modification time and operation information to ensure the accuracy of data synchronization.
[0043] In order to better understand the above technical solution, exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although exemplary embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be limited by the embodiments described herein. On the contrary, these embodiments are provided to enable a more thorough understanding of the present disclosure and to fully convey the scope of the present disclosure to those skilled in the art.
[0044] As an implementation plan, Figure 1 It is a schematic diagram of the architecture of the hardware operating environment of the data synchronization verification system of the bill of materials involved in the embodiment of the present invention.
[0045] like Figure 1As shown, the data synchronization verification system of the bill of materials may include: a processor 1001, such as a CPU, a memory 1005, a user interface 1003, a network interface 1004, and a communication bus 1002. Among them, the communication bus 1002 is used to realize the connection and communication between these components. The user interface 1003 may include a display screen (Display), an input unit such as a keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a WI-FI interface). The memory 1005 may be a high-speed RAM memory, or a stable memory (non-volatile memory), such as a disk memory. The memory 1005 may also be a storage device independent of the aforementioned processor 1001.
[0046] Those skilled in the art will understand that Figure 1 The architecture of the data synchronization verification system for the bill of materials shown in the figure does not constitute a limitation on the data synchronization verification system for the bill of materials, and may include more or less components than shown in the figure, or a combination of certain components, or a different arrangement of components.
[0047] like Figure 1 As shown, the memory 1005 as a storage medium may include an operating system, a network communication module, a user interface module, and a data synchronization verification program for the bill of materials. The operating system is a program that manages and controls the hardware and software resources of the data synchronization verification system for the bill of materials, and the operation of the data synchronization verification program for the bill of materials and other software or programs.
[0048] exist Figure 1 In the data synchronization verification system of the bill of materials shown, the user interface 1003 is mainly used to connect to the terminal and communicate data with the terminal; the network interface 1004 is mainly used for the background server and communicates data with the background server; the processor 1001 can be used to call the data synchronization verification program of the bill of materials stored in the memory 1005.
[0049] In this embodiment, the data synchronization verification system of the bill of materials includes: a memory 1005, a processor 1001, and a data synchronization verification program of the bill of materials stored in the memory and executable on the processor, wherein:
[0050] When the processor 1001 calls the data synchronization verification program of the bill of materials stored in the memory 1005, the following operations are performed:
[0051] Obtain at least one of the data operation object, historical modification time, and historical operation information recorded when the data of the material to be verified in the bill of materials was last updated;
[0052] Determine, according to at least one of the data operation object, the historical modification time and the historical operation information, whether the synchronization status of the material data to be verified satisfies at least one of a preset data conflict verification condition, a data time verification condition and a data integrity verification condition;
[0053] If not satisfied, a synchronization failure prompt is output, and a data synchronization operation is performed on the material data to be verified.
[0054] When the processor 1001 calls the data synchronization verification program of the bill of materials stored in the memory 1005, the following operations are performed:
[0055] Determine whether the number of the data operation objects is single, if so, determine that the synchronization condition satisfies the data conflict check condition, otherwise, determine that it does not satisfy the condition; and / or,
[0056] Determine whether the historical modification time is after the creation time of the material data to be verified on the preset time axis, if so, determine that the synchronization condition meets the data time verification condition, otherwise, determine that it does not meet the condition; and / or,
[0057] Obtain historical material data to be verified before the material data to be verified executes the historical operation information, determine the information integrity between the historical material data to be verified and the material data to be verified, and when the information integrity is greater than or equal to a preset integrity threshold, determine that the synchronization situation meets the data integrity verification condition, otherwise, determine that it is not satisfied.
[0058] When the processor 1001 calls the data synchronization verification program of the bill of materials stored in the memory 1005, the following operations are performed:
[0059] Determine the hash value between each data node corresponding to the material data to be verified and the historical material data to be verified;
[0060] The information integrity is determined according to the hash values between the data nodes.
[0061] When the processor 1001 calls the data synchronization verification program of the bill of materials stored in the memory 1005, the following operations are performed:
[0062] Comparing the hash values between the data nodes, if the hash values between the data nodes are the same, increasing the information integrity based on a preset increment; or,
[0063] If the hash values between the data nodes are the same, the information integrity is set to the target information integrity, wherein the target information integrity is greater than or equal to the integrity threshold.
[0064] When the processor 1001 calls the data synchronization verification program of the bill of materials stored in the memory 1005, the following operations are performed:
[0065] Obtain the current time and the operation object ID field in the cache record table associated with the material data to be verified, and determine the operation object ID field closest to the current time in the timestamp of each operation object ID field as the data operation object recorded at the last update;
[0066] Obtain the current time and the timestamps corresponding to the data modification logs in the cache record table associated with the material data to be verified, and determine the timestamp field closest to the current time among the timestamps as the historical modification time recorded during the last update;
[0067] Obtain the current moment and each data modification log in the cache record table associated with the material data to be verified, and determine the operation information field in the data modification log closest to the current moment in the timestamp corresponding to each data modification log as the historical operation information recorded during the last update.
[0068] When the processor 1001 calls the data synchronization verification program of the bill of materials stored in the memory 1005, the following operations are performed:
[0069] If there are multiple data operation objects, obtain the operation authority level of each of the data operation objects, determine the operation priority of the data operation object according to the operation authority level, and perform the data synchronization operation of each of the data operation objects according to the operation priority based on a preset interval duration;
[0070] If the historical modification time is before the creation time of the material data to be verified, performing the data synchronization operation on the material data to be verified;
[0071] If the information integrity between the historical material data to be verified before the material data to be verified executes the historical operation information and the material data to be verified is less than a preset integrity threshold, the data synchronization operation is performed on the material data to be verified.
[0072] When the processor 1001 calls the data synchronization verification program of the bill of materials stored in the memory 1005, the following operations are performed:
[0073] If satisfied, a prompt indicating successful synchronization is output.
[0074] When the processor 1001 calls the data synchronization verification program of the bill of materials stored in the memory 1005, the following operations are performed:
[0075] At every preset period, return to execute the step of obtaining at least one of the data operation object, the historical modification time and the historical operation information recorded when the data of the material to be verified in the material list was last updated.
[0076] Based on the hardware architecture of the data synchronization verification system of the bill of materials based on the data processing technology, an embodiment of the data synchronization verification method of the bill of materials of the present invention is proposed.
[0077] Reference Figure 2 In a first embodiment, the data synchronization verification method of the bill of materials includes the following steps:
[0078] Step S10, obtaining at least one of the data operation object, historical modification time and historical operation information recorded when the data of the material to be verified in the bill of materials was last synchronized;
[0079] In this embodiment, at least one of the data operation object, the historical modification time, and the historical operation information recorded when the data of the material to be verified in the bill of materials was last synchronized is obtained.
[0080] The material data to be verified is characterized as the material data in the bill of materials that has been synchronized but not verified, and the data operation object is characterized as the user, client, system, PC and other objects with operation authority on the bill of materials. Material data is the data in the BOM (Bill of Materials), including but not limited to information such as parts, materials, quantity, specifications and location of the product. Data synchronization refers to the process of synchronizing material data from design software or systems (such as PDM systems) to ERP (Enterprise Resource Planning) or other production systems during the design and manufacturing of products.
[0081] The historical modification time is represented by the time recorded in the modification log generated when the material data to be verified was modified in the past.
[0082] The historical operation information is the information in the operation record log generated after the operation is performed according to the operation instruction when the material data to be verified receives the operation instruction at the past time.
[0083] Since the material data is stored in the bill of materials, multiple synchronizations are usually performed, and the data operation objects, historical modification times, and historical operation information that need to be obtained in this embodiment are all recorded during the last synchronization.
[0084] It can be understood that in this embodiment, the data of the materials to be verified in the bill of materials will generate a data log corresponding to the synchronization each time the synchronization is performed, and each data log contains at least the aforementioned data operation object, historical modification time and historical operation information.
[0085] Step S20, determining whether the synchronization status of the material data to be verified meets a preset verification condition according to at least one of the data operation object, the historical modification time and the historical operation information;
[0086] In this embodiment, after obtaining at least one of the data operation object, the historical modification time and the historical operation information, the synchronization status of the material data to be verified is determined based on at least one of the data operation object, the historical modification time and the historical operation information, and a verification condition is set to determine whether the synchronization status of the material data to be verified meets the verification condition.
[0087] Before and after the data synchronization operation is performed, data redundancy and data errors are introduced by the data format conversion between the two systems. Therefore, the synchronization status feature is introduced here to characterize the degree of data change of the material data before and after the data synchronization operation is performed. Among them, the synchronization status meets the preset verification conditions, that is, it characterizes the degree of data change of the material data, and will not affect the subsequent modification operations such as adding, deleting, modifying and checking the same material data in two different systems.
[0088] For the data operation object dimension, in the data synchronization link, there are usually multiple objects performing synchronization operations on the material data in the bill of materials, which may cause multiple objects to operate on the same material data at the same time when performing synchronization operations, which will cause data conflicts such as read-write conflicts, write-read conflicts, and write-write conflicts, resulting in data being unable to be correctly synchronized from one system to another. Therefore, in this embodiment, the data operation object recorded when the material data to be verified was last updated is selected as the criterion for synchronization.
[0089] For the modification time dimension, during the data synchronization process, the data cannot be correctly synchronized from one system to another due to the different time when the material data is entered between the two systems. Therefore, in this embodiment, the historical modification time recorded when the material data to be verified was last updated can be used as the criterion for synchronization.
[0090] For the operation information dimension, before and after the data synchronization operation is performed, the material data may be incomplete due to data redundancy and data errors introduced by the data format conversion between the two systems, which in turn causes the data to be unable to be correctly synchronized from one system to another. Therefore, the historical operation information recorded when the material data to be verified was last updated is introduced as the criterion for the synchronization status.
[0091] It is understandable that, since the judgment methods for synchronization status are different among the three dimensions, one of the above-mentioned data operation objects, historical modification time and historical operation information can be used as the judgment criteria for synchronization status, or multiple dimensions can be used as the judgment criteria for synchronization status. Among them, if multiple dimensions are set as synchronization criteria, the judgment can be based on the above three dimensions at the same time, or multiple judgments can be made in a certain order. The specific setting can be made by the developer according to actual needs, and is not limited in this embodiment.
[0092] In this embodiment, the verification condition is used to determine whether the data change degree of the material data to be verified after the synchronization operation is performed is within an acceptable range. If the verification condition is met, it is determined that the data change degree of the material data to be verified is within an acceptable range.
[0093] It should be noted that since there are one or more criteria for the synchronization status, the set verification conditions can also be set to one or more correspondingly, or one verification condition contains multiple sub-verification conditions. It is only necessary to verify each of the aforementioned synchronization conditions, which is not limited in this embodiment.
[0094] Step S30: If not satisfied, output a synchronization failure prompt and perform a data synchronization operation on the material data to be verified.
[0095] In this embodiment, if the synchronization situation does not meet the verification condition, a synchronization failure prompt is outputted indicating that the synchronization has failed, and the data synchronization operation is re-executed on the material data to be verified.
[0096] Optionally, the step of performing data synchronization operation on the material data to be verified may be to prompt the user to re-enter the synchronization operation for the material data after a synchronization failure prompt pops up. Exemplarily, when it is determined that the verification condition is not met, a prompt pop-up window "Verification completed, material data synchronization failed, please re-execute the corresponding operation" pops up in the system interface, and after user A sees the pop-up window, he re-executes the data synchronization operation on the material data.
[0097] Alternatively, after the system determines that synchronization has failed, the last data synchronization operation is reloaded. For example, when it is determined that the verification condition is not met, a prompt pop-up window "Verification completed, material data synchronization failed" pops up in the system interface, and then the historical operation instructions recorded during the most recent update are reloaded, and the material data synchronization operation is re-executed.
[0098] It is understandable that if there are multiple synchronization conditions and verification conditions, a synchronization failure prompt will be output if any verification condition is not met, and the prompt will include which verification condition is not met. For example, a prompt pop-up window will pop up saying "Verification completed, material data synchronization failed, synchronized material data is incomplete, please re-perform the corresponding operation."
[0099] In the technical solution provided in this embodiment, the material data after data synchronization is verified to be correct based on three dimensions: synchronization operation object, modification time and operation information. If it is incorrect, the data synchronization operation is re-executed to ensure the accuracy of data synchronization.
[0100] Furthermore, in this embodiment, after step S20, the following steps are further included:
[0101] Step S40: If the conditions are met, output a synchronization success prompt.
[0102] In the technical solution provided in this embodiment, if the synchronization status of the verified material data meets the preset verification conditions, it is determined that the data change degree of the material data to be verified is within an acceptable range, the data synchronization operation is normal, and a synchronization success prompt is output.
[0103] Optionally, a synchronization success prompt may be sent to a system corresponding to the data synchronization verification method for the bill of materials in this embodiment.
[0104] Exemplarily, there is a system for data synchronization verification of the bill of materials, which can synchronize material data from the PDM system to the ERP system, and can verify the synchronized material data. After completing a synchronization operation for material data BOM1, user A clicks the verification instruction in the system interface, and the verification instruction calls the verification process to verify the material data BOM1. After judging the synchronization status of the material data BOM1 based on the data operation object, historical modification time and / or historical operation information, the synchronization status meets the verification conditions, and a prompt pop-up window "Verification completed, material data synchronization successful" pops up in the system interface.
[0105] In the technical solution provided in this embodiment, if the synchronization situation meets the verification condition, a synchronization success prompt of the synchronization failure is output to ensure the accuracy of data synchronization.
[0106] Reference Figure 3 In the second embodiment, based on any one of the embodiments, step S20 includes:
[0107] Step S21, determining whether the number of the data operation objects is single, if so, determining that the synchronization condition satisfies the data conflict check condition, otherwise, determining that it does not satisfy the condition;
[0108] And / or, step S22, determining whether the historical modification time is located after the creation time of the material data to be verified on the preset time axis, if so, determining that the synchronization condition meets the data date verification condition, otherwise, determining that it does not meet the condition;
[0109] And / or, step S23, obtaining the historical material data to be verified before the material data to be verified executes the historical operation information, determining the information integrity between the historical material data to be verified and the material data to be verified, and when the information integrity is greater than or equal to a preset integrity threshold, determining that the synchronization situation meets the data integrity verification condition, otherwise, determining that it is not met.
[0110] As an optional embodiment, this embodiment provides a method for determining the synchronization status according to the data operation object, the historical modification time and / or the historical operation information.
[0111] Specifically, for the data operation object dimension, the verification condition used is the data conflict verification condition. The number of data operation objects is obtained, and it is determined whether the number of data operation objects is single. If it is single, it is determined that only one object performed data synchronization operation on the material data during the last synchronization, which means that the data does not conflict, and the data verification based on the data operation object dimension is qualified.
[0112] Regarding the modification time dimension, during the data synchronization process, the data date may change due to data format conversion, resulting in the modification time of the material data being mistakenly recorded before the creation time of the material data, which may easily lead to the next data synchronization prompting that the material has been deleted or has not taken effect or has expired. Therefore, in this embodiment, the verification condition used is the data date verification condition, and a time axis is preset. When any operation (including creation, update, and deletion) is performed on the material data, the time when the operation is performed will be recorded on the time axis as the modification time. When it is judged that the modification time recorded during the last synchronization is recorded on the time axis after the creation time of the material data, it means that the material synchronization operation did not cause the data date to change or the date change did not affect the next data synchronization, and the data verification based on the modification time dimension is qualified.
[0113] With respect to the operation information dimension, during the data synchronization process, the synchronized data may be incomplete due to data redundancy, data errors, etc. caused by data format conversion, which may lead to errors in the next data synchronization. Therefore, in this embodiment, when obtaining the last synchronization of the material data to be verified, the historical material data to be verified before the historical operation information is executed to determine the information integrity between the historical material data to be verified and the material data to be verified. The information integrity is characterized by a quantitative value of the data integrity before and after the data synchronization operation is performed on the material data to be verified. When the information integrity is greater than or equal to the preset integrity threshold, it is determined that the synchronization situation meets the data integrity verification condition, and the data verification based on the operation information dimension is qualified.
[0114] It is understandable that one of the above-mentioned dimensions of data operation object, historical modification time and historical operation information can be used as the criterion for synchronization, or multiple dimensions can be used as the criterion for synchronization. If multiple dimensions are set as synchronization criteria, the judgment can be made based on the above three dimensions at the same time, or multiple judgments can be made in a certain order. The specific setting can be made by the developer according to actual needs, and is not limited in this embodiment.
[0115] In the technical solution provided in this embodiment, the material data to be verified is verified based on at least one of the number of data operation objects, the circadian relationship between historical modification time and creation time, and / or the information integrity between historical material data to be verified and the material data to be verified, so as to ensure the accuracy of data synchronization.
[0116] Further, in this embodiment, the step of determining the information integrity between the historical material data to be verified and the material data to be verified in step S23 includes:
[0117] Step S231, determining the hash values between the data nodes corresponding to the material data to be verified and the historical material data to be verified;
[0118] Step S232: Determine the information integrity according to the hash value between each of the data nodes.
[0119] Optionally, in this embodiment, a method for determining information integrity based on a hash value is provided. The hash value is characterized as an identity identifier of the data, and is a fixed-length binary value generated according to the size, creation time, and data type of the material data.
[0120] It should be noted that in this embodiment, when the material data is synchronized from one database to another during data synchronization, the hash value in its data structure will not change. Therefore, the integrity of the information in the data can be determined by comparing the hash values of the material data before and after synchronization.
[0121] In this embodiment, whether it is material data stored in the PDM system or material data synchronized to the ERP system, a tree structure is used to construct a hash value tree. The hash value in each data node in the hash value tree corresponding to the material data after the data synchronization operation is performed is compared with the hash value in each data node in the hash value tree of the historical material data to be verified before the last synchronization operation is performed, so as to determine whether the data in the data node has changed when synchronized to another system based on whether the hash values are the same.
[0122] Optionally, the hash value may be calculated using a SHA-256 algorithm to calculate the hash value of each node in the material data structure.
[0123] Exemplarily, the material data to be verified is divided into three nodes (A, B, C), and their hash values (hash_A, hash_B, hash_C) are calculated respectively. For the data of the three corresponding nodes (A_his, B_his, C_his) in the historical material data to be verified, the hash values (hash_A_his, hash_B_his, hash_C_his) are also calculated respectively. Then, the material data to be verified and the corresponding node hash values in the historical material data to be verified are compared in turn. For example, compare whether the hash value hash_A of node A is consistent with the hash value hash_A_his of node A_his. If the hash values are inconsistent, it means that the node A of the current data has data tampering or loss, and the information is incomplete. Similarly, compare the hash values of nodes B and C, and after comparing the hash values of each node, determine the information integrity.
[0124] In the technical solution provided in this embodiment, the information integrity between the material data to be verified and the historical material data to be verified is determined based on the hash value, so that the material data to be verified is verified based on the dimension of historical operation information to ensure the accuracy of data synchronization.
[0125] Furthermore, in this embodiment, step S232 includes the following steps:
[0126] Step S2321, comparing the hash values between the data nodes, and if the hash values between the data nodes are the same, increasing the information integrity based on a preset increment;
[0127] Or, step S2322, if the hash values between the data nodes are the same, the information integrity is set to the target information integrity, wherein the target information integrity is greater than or equal to the integrity threshold.
[0128] Optionally, this embodiment further provides two methods for determining information completeness.
[0129] The first method is to compare the hash values in each data node separately. Specifically, the initial value of the information integrity is set to 0. When the hash values of a corresponding data node between two data are the same, the information integrity is increased based on a preset increment.
[0130] Exemplarily, suppose the material data to be verified are three nodes (A, B, C), and the corresponding three nodes in the historical material data to be verified are (A_his, B_his, C_his), and the preset increment is ΔH>0.
[0131] Compare the hash values of node A and node A_his. If they are the same, the information integrity increases to ΔH.
[0132] Compare the hash values of node B and node B_his. If they are the same, the information integrity increases to 2ΔH.
[0133] Compare the hash values of node C and node C_his. If they are different, the information integrity remains at 2ΔH.
[0134] Finally, the information completeness after output comparison is 2ΔH.
[0135] Compare 2ΔH with the integrity threshold H0. If 2ΔH≥H0, it is determined that the synchronization situation meets the data integrity verification condition; if 2ΔH<H0, it is determined that the synchronization situation does not meet the condition.
[0136] The second method is to compare the hash values between the material data to be verified and the historical material data to be verified as a whole. Specifically, during the data transmission process, each data node sends its own hash value to the next node. When the last node receives the data and calculates its own hash value, it sends it to the first node. After the first node receives the hash values of all nodes, it compares whether the adjacent hash values between them are consistent. If there is an inconsistency, it means that data corruption or tampering has occurred during the information transmission process. If all hash values are consistent, it means that no data corruption or tampering has occurred during the information transmission process, and the information integrity is directly set to a target integrity greater than the integrity threshold, that is, it is directly judged that the synchronization situation meets the data integrity verification conditions.
[0137] In the technical solution provided in this embodiment, the information integrity between the material data to be verified and the historical material data to be verified is determined by two methods: individual comparison and overall comparison. If the individual comparison method is used for verification, each time the hash values of a pair of data nodes are determined to be the same, the information integrity is increased to a certain value. After each data node is compared, it is determined whether the current information integrity is greater than the preset data threshold. If it is greater than, it is determined that the synchronization situation meets the data integrity verification condition, that is, if a node in the synchronized material data has a data deviation, when the deviation is still within an acceptable range, it is still determined that the synchronization is successful. If the overall comparison method is used for verification, it means that each node in the synchronized material data is not allowed to have a deviation, and the synchronization is judged to be successful only when the hash values of each node are the same. When the amount of data in the material data is large and the synchronized data is easy to change, the individual comparison method can be used for verification; when the amount of data in the material data is small, or the data accuracy requirements before and after the synchronization of the material data are high, the overall comparison method can be used for verification. Thereby, the material data to be verified is verified based on the dimension of historical operation information to ensure the accuracy of data synchronization.
[0138] Reference Figure 4 In the third embodiment, based on any one of the embodiments, the step S30 of performing data synchronization on the material data to be verified includes at least one of the following:
[0139] Step S31, if there are multiple data operation objects, obtain the operation authority level of each of the data operation objects, determine the operation priority of the data operation object according to the operation authority level, and perform the data synchronization operation of each of the data operation objects according to the operation priority based on a preset interval duration;
[0140] As an optional embodiment, in this embodiment, different permission levels are assigned in advance to each data operation object that has operation authority over material data. If there are multiple objects that perform operations on the material data to be verified, the operation permission level of each data operation object is obtained, the operation priority of the data operation object is determined according to the operation permission level, and the data synchronization operation of each data operation object is performed according to the operation priority based on a preset interval duration.
[0141] Based on the operation permission level obtained in the previous step, the system will determine the operation priority of each data operation object. Objects with high operation priority will perform data synchronization operations first, and objects with low operation priority will perform them later.
[0142] Moreover, in this embodiment, the system will only perform data synchronization operations on the data operation object with the highest priority currently determined within a preset interval, and after the interval, determine the data operation object with the highest priority for the next cycle, and repeat this process to avoid performing too many synchronization operations on data in a short period of time.
[0143] Step S32, if the historical modification time is before the creation time of the material data to be verified, performing the data synchronization operation on the material data to be verified;
[0144] As an optional embodiment, in this embodiment, a data synchronization operation is performed on the historical material data to be verified: if the historical modification time of the material data to be verified is before its creation time, a data synchronization operation will be performed on these data to ensure that they are synchronized with the latest data in the system.
[0145] Step S33: If the information integrity between the historical material data to be verified before the material data to be verified executes the historical operation information and the material data to be verified is less than a preset integrity threshold, the data synchronization operation is performed on the material data to be verified.
[0146] As an optional embodiment, in this embodiment, the information integrity of historical material data to be verified is checked. If the information integrity between the historical material data to be verified before the material data to be verified executes the historical operation information and the material data to be verified is less than a preset integrity threshold, a data synchronization operation will be performed on the material data to be verified to ensure that its information integrity meets the preset requirements.
[0147] In the technical solution provided in this embodiment, if the synchronization situation does not meet the corresponding verification conditions, the data synchronization operation is performed on the material data to be verified according to the specific synchronization situation of the material data to ensure the accuracy of data synchronization.
[0148] Reference Figure 5 In a fourth embodiment, based on any embodiment, after step S30, the method further includes:
[0149] Step S50, every preset period, return to execute the step of obtaining at least one of the data operation object, historical modification time and historical operation information recorded when the data of the material to be verified in the material list was last updated.
[0150] As an optional embodiment, in this embodiment, the system can automatically perform data synchronization verification on the material data to be synchronized, set a period, and after performing the data synchronization operation on the material data to be verified, perform the steps of obtaining the data operation object, historical modification time and historical operation information recorded when the material data to be verified in the bill of materials was last updated, and the subsequent corresponding verification steps again after the period, that is, the data synchronization verification will be automatically performed after each data synchronization is completed. In this way, the accuracy of material data synchronization is ensured.
[0151] In addition, it can be understood by a person skilled in the art that all or part of the processes in the method for implementing the above embodiment can be completed by instructing the relevant hardware through a computer program. The computer program includes program instructions, and the computer program can be stored in a storage medium, which is a computer-readable storage medium. The program instructions are executed by at least one processor in the data synchronization verification system of the bill of materials to implement the process steps of the embodiment of the above method.
[0152] Therefore, the present invention also provides a computer-readable storage medium, which stores a data synchronization verification program for a bill of materials. When the data synchronization verification program for the bill of materials is executed by a processor, the various steps of the data synchronization verification method for the bill of materials described in the above embodiment are implemented.
[0153] The computer-readable storage medium may be a USB flash drive, a mobile hard disk, a read-only memory (ROM), a magnetic disk, or an optical disk, etc., which may store program codes.
[0154] It should be noted that since the storage medium provided in the embodiment of the present application is the storage medium used to implement the method of the embodiment of the present application, based on the method introduced in the embodiment of the present application, the person skilled in the art can understand the specific structure and deformation of the storage medium, so it is not repeated here. All storage media used in the method of the embodiment of the present application belong to the scope of protection of this application.
[0155] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0156] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0157] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0158] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0159] It should be noted that in the claims, any reference signs placed between brackets shall not be construed as limiting the claims. The word "comprising" does not exclude the presence of components or steps not listed in the claim. The word "a" or "an" preceding a component does not exclude the presence of a plurality of such components. The invention may be implemented by means of hardware comprising several different components and by means of a suitably programmed computer. In a unit claim enumerating several means, several of these means may be embodied by the same item of hardware. The use of the words first, second, and third etc. does not indicate any order. These words may be interpreted as names.
[0160] Although the preferred embodiments of the present invention have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the present invention.
[0161] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.
Claims
1. A data synchronization verification method for a bill of materials, characterized in that: The data verification method of the bill of materials includes: Obtain at least one of the data operation object, historical modification time, and historical operation information recorded when the data of the material to be verified in the bill of materials was last updated; According to at least one of the data operation object, the historical modification time and the historical operation information, determine whether the synchronization status of the material data to be verified meets at least one of a preset data conflict verification condition, a data time verification condition and a data integrity verification condition, wherein the synchronization status represents the degree of data change of the material data to be verified before and after the data synchronization operation is performed, and the data conflict verification condition, the data time verification condition and the data integrity verification condition are used to determine whether the degree of data change of the material data to be verified after the synchronization operation is performed is within an acceptable range; If not, a synchronization failure prompt is output, and a data synchronization operation is performed on the material data to be verified; The step of obtaining at least one of the data operation object, the historical modification time and the historical operation information recorded when the data of the material to be verified in the bill of materials was last updated includes: Obtain the current time and the operation object ID field in the cache record table associated with the material data to be verified, and determine the operation object ID field closest to the current time in the timestamp of each operation object ID field as the data operation object recorded at the last update; Obtain the current time and the timestamps corresponding to the data modification logs in the cache record table associated with the material data to be verified, and determine the timestamp field closest to the current time among the timestamps as the historical modification time recorded during the last update; Obtain the current time and each data modification log in the cache record table associated with the material data to be verified, and determine the operation information field in the data modification log closest to the current time in the timestamp corresponding to each data modification log as the historical operation information recorded during the last update; The step of determining whether the synchronization status of the material data to be verified satisfies at least one of a preset data conflict verification condition, a data time verification condition, and a data integrity verification condition according to at least one of the data operation object, the historical modification time, and the historical operation information comprises: Determine whether the number of the data operation objects is single, if so, determine that the synchronization condition satisfies the data conflict check condition, otherwise, determine that it does not satisfy the condition; and / or, Determine whether the historical modification time is after the creation time of the material data to be verified on the preset time axis, if so, determine that the synchronization condition meets the data time verification condition, otherwise, determine that it does not meet the condition; and / or, Obtain historical material data to be verified before the material data to be verified executes the historical operation information, determine the information integrity between the historical material data to be verified and the material data to be verified, and when the information integrity is greater than or equal to a preset integrity threshold, determine that the synchronization situation meets the data integrity verification condition, otherwise, determine that it is not satisfied.
2. The method for data synchronization verification of a bill of materials as claimed in claim 1, characterized in that: The step of determining the information integrity between the historical material data to be verified and the material data to be verified comprises: Determine the hash value between each data node corresponding to the material data to be verified and the historical material data to be verified; The information integrity is determined according to the hash values between the data nodes.
3. The method for data synchronization verification of a bill of materials as claimed in claim 2, characterized in that: The step of determining the information integrity according to the hash values between the data nodes comprises: Comparing the hash values between the data nodes, if the hash values between the data nodes are the same, increasing the information integrity based on a preset increment; or, If the hash values between the data nodes are the same, the information integrity is set to the target information integrity, wherein the target information integrity is greater than or equal to the integrity threshold.
4. The method for data synchronization verification of a bill of materials as claimed in claim 1, characterized in that: The step of performing a data synchronization operation on the material data to be verified includes at least one of the following: If there are multiple data operation objects, obtain the operation authority level of each of the data operation objects, determine the operation priority of the data operation object according to the operation authority level, and perform the data synchronization operation of each of the data operation objects according to the operation priority based on a preset interval duration; If the historical modification time is before the creation time of the material data to be verified, performing the data synchronization operation on the material data to be verified; If the information integrity between the historical material data to be verified before the material data to be verified executes the historical operation information and the material data to be verified is less than a preset integrity threshold, the data synchronization operation is performed on the material data to be verified.
5. The method for data synchronization verification of a bill of materials as claimed in claim 1, characterized in that: After the step of determining whether the synchronization status of the material data to be verified satisfies at least one of a preset data conflict verification condition, a data time verification condition, and a data integrity verification condition according to at least one of the data operation object, the historical modification time, and the historical operation information, the method further includes: If satisfied, a prompt indicating successful synchronization is output.
6. The method for data synchronization and verification of a bill of materials as claimed in claim 1, characterized in that: After the steps of outputting a synchronization failure prompt and performing a data synchronization operation on the material data to be verified, the method further includes: At every preset period, return to execute the step of obtaining at least one of the data operation object, the historical modification time and the historical operation information recorded when the data of the material to be verified in the material list was last updated.
7. A data synchronization verification system for a bill of materials, characterized in that: The data synchronization verification system equipment of the bill of materials includes: a memory, a processor, and a data synchronization verification program of the bill of materials stored in the memory and executable on the processor. When the data synchronization verification program of the bill of materials is executed by the processor, the steps of the data synchronization verification method of the bill of materials as described in any one of claims 1 to 6 are implemented.
8. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a data synchronization verification program for the bill of materials, and when the data synchronization verification program for the bill of materials is executed by the processor, the steps of the data synchronization verification method for the bill of materials as described in any one of claims 1 to 6 are implemented.
