Data processing method and related equipment
By obtaining the start and end times of the zipper list, determining the first and second times, and quickly repairing the zipper record, the problem of low repair efficiency in the prior art is solved, and a more efficient repair process is achieved.
Patent Information
- Application Number
- CN202411497419.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-24
- Publication Date
- 2025-03-25
AI Technical Summary
The prior art is inefficient in repairing missing zipper records in zipper lists and the repair process is complicated.
By obtaining the start time and the end time of the first data of the zipper list, the first time is determined based on the termination time, and the second time between the start time and the first time is calculated based on the predesign calculation rules to determine a zipper record.
Simplifies the repair process of zipper records, shortens repair time, and improves repair efficiency.
Smart Images

Figure CN119690949A_ABST
Abstract
Description
Background Art
[0002] As a data table structure, zipper table is widely used in business environments such as business databases and data warehouses. It effectively saves storage space by recording data changes. In the actual production process, zipper table data may be lost abnormally. In order to ensure the normal operation of the system, the zipper table data needs to be repaired.
[0003] However, due to the unique data structure of the zipper table, the repair process of missing zipper records is relatively complicated and the repair efficiency is low.
[0004] It should be noted that the information disclosed in the above background technology section is only used to enhance the understanding of the background of the present disclosure, and therefore may include information that does not constitute the prior art known to ordinary technicians in the field. Summary of the invention
[0005] The present disclosure provides a data processing method and related equipment, which improves the efficiency of repairing missing zipper records.
[0006] Other features and advantages of the present disclosure will become apparent from the following detailed description, or may be learned in part by the practice of the present disclosure.
[0007] According to one aspect of the present disclosure, a data processing method is provided, including: obtaining the start time and end time of first data of a zipper table; determining a first time based on the end time, the first time being the difference between the end time and a unit time; calculating a second time between the start time and the first time based on a preset calculation rule, the second time being a deadline for data having the same cross-section as the start time; and determining a zipper record of the first data based on the start time and the second time.
[0008] According to another aspect of the present disclosure, a data processing device is provided, including: an acquisition module, used to acquire the start time and end time of first data of a zipper table; a determination module, used to determine the first time based on the end time, the first time being the difference between the end time and the unit time; the determination module is also used to calculate the second time between the start time and the first time based on a preset calculation rule, the second time being a deadline for data having the same cross-section as the start time; the determination module is also used to determine a zipper record of the first data based on the start time and the second time.
[0009] According to another aspect of the present disclosure, an electronic device is provided, comprising: a processor; and a memory for storing executable instructions of the processor; wherein the processor is configured to perform any of the above-mentioned data processing methods by executing the executable instructions.
[0010] According to another aspect of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, any of the above-mentioned data processing methods is implemented.
[0011] According to another aspect of the present disclosure, a computer program product is provided, wherein the computer program product comprises a computer program or computer instructions, wherein the computer program or the computer instructions are loaded and executed by a processor so that a computer implements any of the above-mentioned data processing methods.
[0012] In the embodiment of the present disclosure, the start time and the end time of the first data of the zipper table are obtained, and the first time is determined based on the end time, the first time is the difference between the end time and the unit time, and then the second time between the start time and the first time is calculated based on the preset calculation rule, the second time is the deadline with the same cross-sectional data as the start time; and a zipper record of the first data is determined based on the start time and the second time. The present disclosure determines the first time through the end time of the first data, and can quickly determine the deadline with the same cross-sectional data as the start time based on the preset calculation rule, thereby determining a zipper record of the first data. The present disclosure simplifies the repair process of the zipper record, shortens the repair time of the zipper record, and improves the repair efficiency.
[0013] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] The accompanying drawings herein are incorporated into the specification and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the specification are used to explain the principles of the present disclosure. Obviously, the accompanying drawings described below are only some embodiments of the present disclosure, and for ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without creative work.
[0015] Figure 1 A schematic diagram showing a data processing system architecture in an embodiment of the present disclosure.
[0016] Figure 2 A flow chart of a data processing method in an embodiment of the present disclosure is shown.
[0017] Figure 3 A second time determination number axis diagram in an embodiment of the present disclosure is shown.
[0018] Figure 4 A second time determination number axis diagram in another embodiment of the present disclosure is shown.
[0019] Figure 5 A flow chart of a data processing method in another embodiment of the present disclosure is shown.
[0020] Figure 6 A number line diagram of a complete zipper table in one embodiment of the present disclosure is shown.
[0021] Figure 7 A zipper table number axis diagram of missing data in one embodiment of the present disclosure is shown.
[0022] Figure 8 A schematic diagram showing a missing interval in an embodiment of the present disclosure.
[0023] Fig. 9 A schematic diagram of a data processing device in an embodiment of the present disclosure is shown.
[0024] Fig.10 A structural block diagram of an electronic device in an embodiment of the present disclosure is shown.
[0025] Fig.11 A schematic diagram of a computer-readable storage medium provided in an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0026] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be implemented in a variety of forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that the disclosure will be more comprehensive and complete and to fully convey the concepts of the example embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
[0027] In addition, the accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and their repeated description will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor devices and / or microcontroller devices.
[0028] It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.
[0029] It should be noted that the concepts such as "first" and "second" mentioned in the present disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.
[0030] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".
[0031] For ease of understanding, several terms involved in the present disclosure are explained below:
[0032] Section date: the date on which the data warehouse extracts business system data.
[0033] Section: A snapshot of data. For a full scale, each section contains the full data up to the date of that section.
[0034] Cross-sectional data: data captured from the zipper table data structure at a specific time point or time period. For example, as shown in Table 1 below, the data captured at the time point of 2020-06-01 includes account resource 1000 and credit resource 5000, that is, account resource 1000 and credit resource 5000 are cross-sectional data at 2020-06-01.
[0035] Full table: records all data within the update cycle, regardless of whether the data has changed.
[0036] Data primary key (also known as cross-section data): a field that can uniquely identify a piece of data in each data cross-section.
[0037] Zipper table: A table that records all changes in information from the beginning to the current state of a thing. Compared with a full table, a zipper table records the life cycle of data through the zipper start time and the zipper end time, reduces duplicate records, and can save storage space to the maximum extent.
[0038] Zipper start time (also known as start date): represents the start time when the data (a zipper record) takes effect.
[0039] Zipper end time (also called end date): represents the end time when the data (a zipper record) takes effect. Usually used in conjunction with the zipper start time.
[0040] Creation date (create_time): The date when the data record is created, or the date when the business occurs. All table data will record the data creation date.
[0041] As a data table structure, zipper tables are widely used in business environments such as business databases and data warehouses. Zipper tables save space by recording changed data. In the actual production process, different scenarios will cause the loss of zipper table data. For example, abnormal data deletion in the business system will cause the loss of zipper table data. For another example, an abnormal data processing process causes data to be mistakenly deleted, resulting in the loss of zipper table data. For another example, the cluster is abnormal, and the data block of the underlying storage HDFS (Hadoop Distributed File System, a distributed file system) is lost, resulting in the loss of zipper table data. The present disclosure is not limited to the zipper table data loss in the above-mentioned scenarios. It should be noted that the data missing from the zipper table is the first data (data to be repaired) on the zipper table of the present disclosure. The following two tables illustrate the data to be repaired in the zipper table. Table 1 shows a complete example of a zipper table. Table 2 shows an example of missing data in a zipper table.
[0042] Table 1 Account resource zipper table (complete)
[0043]
[0044] Table 2 Account resource zipper table (missing)
[0045]
[0046] It can be seen from Table 1 and Table 2 above that the zipper table includes multiple zipper records (each row of data in the zipper table is a zipper record), Table 2 is the zipper table after the data in Table 1 is lost, and the present disclosure is used to repair the data in Table 2, and the data in Table 1 is obtained after the repair. The 2nd row, the 3rd row, the 6th row and the 7th row in Table 1 are the data to be repaired in Table 2 (such as the first data).
[0047] In the related art, the process of repairing missing data in the zipper table is as follows: the detected missing section range is calculated one by one in batches, that is, for the data in the missing range, each unit time interval must be calculated once to complete the supplement. When the missing section range is large, the efficiency will be very low. For example, the unit time is 1 day, and for the data in the missing range, it must be calculated once every day to complete it. If the missing section range is from June 1, 2018 to June 1, 2021, then to repair the missing data (zipper record), it is necessary to calculate every day within the time range. It can be seen that the process of repairing missing zipper records in the related technology is relatively complicated and the repair efficiency is low.
[0048] Based on this, the embodiments of the present disclosure provide a data processing method and related equipment, which can be applied to the scenario of repairing missing data in a zipper table. For example, it is applied to application scenarios such as repairing missing data in a warehouse zipper table and repairing missing data in a virtual resource zipper table, and the embodiments of the present disclosure do not specifically limit this. The present disclosure obtains the start time and end time of the first data of the zipper table, and determines the first time based on the end time, the first time is the difference between the end time and the unit time, and then calculates the second time between the start time and the first time based on a preset calculation rule, the second time is the deadline with the same cross-sectional data as the start time; and determines a zipper record of the first data based on the start time and the second time. The present disclosure determines the first time through the end time of the first data, and can quickly determine the deadline with the same cross-sectional data as the start time based on the preset calculation rule, thereby determining a zipper record of the first data. The present disclosure simplifies the repair process of the zipper record, shortens the repair time of the zipper record, and improves the repair efficiency.
[0049] Figure 1 A schematic diagram showing the structure of a data processing system in one embodiment of the present disclosure is provided. The system can apply the data processing method or data processing device in each embodiment of the present disclosure.
[0050] like Figure 1 As shown, the system architecture may include a device 101 and a server 102. The device 101 and the server 102 are connected to each other through a network, which may be a wired network or a wireless network.
[0051] Optionally, the wireless network or wired network described above uses standard communication technology and / or protocol. The network is usually the Internet, but it can also be any network, including but not limited to a local area network (LAN), a metropolitan area network (MAN), a wide area network (WAN), a mobile, wired or wireless network, a dedicated network or any combination of a virtual private network). In some embodiments, technologies and / or formats including Hyper Text Mark-up Language (HTML), Extensible Markup Language (XML), etc. are used to represent data exchanged through the network. In addition, conventional encryption technologies such as Secure Socket Layer (SSL), Transport Layer Security (TLS), Virtual Private Network (VPN), Internet Protocol Security (IPsec) can also be used to encrypt all or some links. In other embodiments, customized and / or dedicated data communication technologies can also be used to replace or supplement the above data communication technologies.
[0052] The device 101 is used to send a request for processing the zipper table data, and can also receive a message of successful data processing sent by the server 102. The device 101 can be various electronic devices, including but not limited to smart phones, tablet computers, laptop computers, desktop computers, wearable devices, augmented reality devices, virtual reality devices, etc. It should be noted that the device 101 can also repair the data to be repaired on the zipper table by itself.
[0053] Optionally, the client of the application installed in different devices 101 is the same, or the client of the same type of application based on different operating systems. Based on the different terminal platforms, the specific form of the client of the application can also be different, for example, the application client can be a mobile client, a PC (Personal Computer) client, etc.
[0054] The server 102 is used to repair the first data according to the zipper table data processing request sent by the device 101, and send a message of successful data processing to the device 101, and the device 101 can view the repaired zipper table. The server 102 can be a server that provides various services, for example, a background management server that provides support for the device operated by the user or the server using the device 101. The background management server can analyze and process the received request and other data, and feed back the processing results to the device.
[0055] Optionally, the server can be an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network), as well as big data and artificial intelligence platforms.
[0056] It should be noted that both the device and the server can repair the data to be repaired, and the use of the device and / or the server to repair the data on the zipper table is determined based on the specific application scenario and actual application experience.
[0057] Those skilled in the art will know that Figure 1 The number of devices and servers in the embodiment is only for illustration, and any number of devices and servers may be provided according to actual needs. The embodiments of the present disclosure do not limit this.
[0058] The present exemplary implementation is described in detail below with reference to the accompanying drawings and embodiments.
[0059] A data processing method is provided in an embodiment of the present disclosure. The method can be executed by any electronic device with computing and processing capabilities, for example, the device or server in the above embodiments.
[0060] Figure 2 A flow chart of a data processing method in an embodiment of the present disclosure is shown as follows: Figure 2 As shown, the data processing method provided in the embodiment of the present disclosure may include the following S201 to S204.
[0061] S201, obtaining the start time and end time of the first data of the zipper table.
[0062] In the disclosed embodiment, the first data is the data to be repaired on the zipper table, that is, the missing data on the zipper table. The first data may include at least one zipper record missing on the zipper table. The start time of the first data is the start date of the first missing zipper record. The end time of the first data is the end date of the last missing zipper record. It should be noted that when the first data includes a zipper record, the start time is the start date of the zipper record, and the end time is the end date of the zipper record.
[0063] In the disclosed embodiment, obtaining the start time and end time of the first data in the zipper table can determine the repair time interval, so that the repair area (such as the missing zipper record in Table 2) can be located more accurately, which is conducive to improving the repair speed.
[0064] S202, determining a first time based on the end time, where the first time is a difference between the end time and the unit time.
[0065] In the disclosed embodiment, according to the characteristics of the zipper table, the end date of the previous zipper record in two adjacent zipper records is the start date of the next zipper record. When obtaining cross-sectional data, the cross-sectional data of the end date of the previous zipper record is the record data of the next zipper record. Therefore, when determining the first time, it is necessary to subtract the unit time from the end time to obtain the first time.
[0066] In the embodiment of the present disclosure, the unit time is the minimum time for recording time changes on the zipper table. The specific size of the unit time can be determined according to the data on the time zipper table, and the embodiment of the present disclosure does not limit it. For example, the unit time can be 1 day (such as Table 1). For another example, the unit time can be 1 hour. For another example, the unit time can be 1 minute.
[0067] S203, calculating a second time between the start time and the first time based on a preset calculation rule, where the second time is a deadline having the same cross-sectional data as the start time.
[0068] In the embodiment of the present disclosure, the preset calculation rule is a rule that can quickly determine the second time from the start time and the first time. Exemplarily, the second time between the start time and the first time is calculated based on the N-division method. Wherein N is greater than or equal to 2. In the embodiment of the present disclosure, there is no limitation on the value of N. For example, the value of N can be any one of 2, 3, 4, 5, 6, 7, 8, 9 and 10. It should be noted that the value of N determines the time for determining the second time, which can be determined according to the actual application scenario and specific application experience. The embodiment of the present disclosure can also calculate the second time by other preset calculation rules, which is not limited by the present disclosure.
[0069] In the disclosed embodiment, the deadline is the maximum time that has the same cross-sectional data as the start time. Exemplarily, the time period that has the same cross-sectional data as the start time is [E, F], that is, the cross-sectional data of any time in the time period [E, F] is the same as the cross-sectional data of the start time. Among them, F in the time period is the deadline. Exemplarily, E is the start time, F is the second time, and the cross-sectional data within [start time, second time] is the same as the cross-sectional data of the start time.
[0070] It should be noted that the present disclosure is applied in a zipper table with certain attributes, and the same data field value in the zipper table can only appear in continuous time intervals and cannot exist across time zones. For example, the loan resource information in the financial industry, the business characteristics determine that after a resource is loaned out, the resource will only decrease as the resource is returned, and will not increase or decrease suddenly. The zipper table of fields with similar characteristics to the resources can be efficiently repaired using the method disclosed in the present disclosure. However, some business fields, such as the credit resources of a contract, are not suitable for the present disclosure. Because the credit resources will change in different periods, such as the data field value from 1000->5000->3000->1000, this kind of zipper table performance cannot use the method disclosed in the present disclosure to narrow the time interval range.
[0071] S204: Determine a zipper record of the first data based on the start time and the second time.
[0072] In the disclosed embodiment, since the cross-sectional data in the time period [start time, second time] is the same, determining the end date of a zipper record based on the start time and the second time requires adding the unit time to the second time.
[0073] In the disclosed embodiment, the start time is used as the start date of the zipper record, the sum of the second time and the unit time is used as the end date of the zipper record, and the cross-sectional data of the start date is used as the missing data of the zipper record (non-date data, such as account resources and credit resources in Table 1). The start date, end date and cross-sectional data are used to repair a missing zipper record.
[0074] The embodiment of the present disclosure determines the first time by the end time of the first data, and can quickly calculate the end date of the data with the same cross section as the start time based on the preset calculation rules, thereby determining a zipper record of the first data. The present disclosure simplifies the repair process of the zipper record, shortens the repair time of the zipper record, and improves the repair efficiency. When the first data is a series of zipper records, the first zipper record can be repaired through the above embodiment, and the other zipper records can be repaired through the following exemplary embodiments.
[0075] In an exemplary embodiment, after determining a zipper record of the first data based on the start time and the second time, the data processing method may further include the following steps A1 to A3.
[0076] Step A1, when the third time is less than the first time, calculate the fourth time between the third time and the first time based on the preset calculation rules, the fourth time is the deadline for having the same cross-sectional data as the third time, and the third time is the sum of the second time and the unit time.
[0077] In the disclosed embodiment, the third time is the end date of repairing the first zipper record in the above embodiment, and the third time is also the start date of the second zipper record.
[0078] Exemplarily, when the third time is less than the first time, where the third time is the sum of the second time and the unit time, a fourth time between the third time and the first time is determined based on a preset calculation rule, and the fourth time is the maximum time (deadline) having the same cross-sectional data as the third time.
[0079] In the disclosed embodiment, by comparing the magnitude relationship between the third time and the first time, it can be determined whether it is necessary to determine the end time (the sum of the fourth time and the unit time) of the second zipper record based on the preset calculation rule, that is, according to the magnitude relationship between the third time and the first time, it is determined whether to determine the fourth time of the second zipper record based on the preset calculation rule. If the third time is less than the first time, it is necessary to determine the fourth time of the second zipper record based on the preset calculation rule. If the third time is equal to the first time, step A3 is executed, and it is not necessary to determine the fourth time of the second zipper record based on the preset calculation rule.
[0080] Step A2: determining a zipper record based on the third time and the fourth time.
[0081] In the disclosed embodiment, the method of determining a zipper record in step A2 is the same as the determination method in step S204, which will not be described in detail here. The third time is used as the start date of the second zipper record to be repaired, the sum of the fourth time and the unit time is used as the end date of the second zipper record to be repaired, the cross-sectional data of the start date is used as the missing data of the zipper record, and the start date, end date and cross-sectional data are used to repair the second zipper record to be repaired.
[0082] It should be noted that the repair method of other zipper records to be repaired is the same as the repair method of the second zipper record to be repaired, which will not be repeated here.
[0083] Step A3: when the third time is equal to the first time, determine a zipper record based on the third time and the end time.
[0084] In the disclosed embodiment, if the third time is equal to the first time, it means that the end date of the second zipper record to be repaired is the termination time, that is, the first data includes two zipper records to be repaired.
[0085] The disclosed embodiment can perform reduced repair on multiple consecutive missing zipper records, and the repair process is simple, which shortens the repair time of the zipper records and improves the repair efficiency.
[0086] In addition, since the embodiment of the present disclosure does not need to obtain and process cross-sectional data of all dates, the computing power of the electronic device is saved, making the operation of the electronic device more stable.
[0087] The above describes how to repair the consecutive missing zipper records. The following describes how to determine the second time through two exemplary embodiments. It should be noted that the method for determining the fourth time is the same as the method for determining the second time.
[0088] In an exemplary embodiment, the second time is determined based on a binary method. It should be noted that the second time can be determined quickly by using a binary method.
[0089] In another exemplary embodiment, calculating a second time between the start time and the first time based on a preset calculation rule, where the second time is a deadline having the same cross-sectional data as the start time, may include the following steps B1 to B4.
[0090] Step B1, taking the start time as the interval start time and the first time as the interval end time.
[0091] In the embodiment of the present disclosure, a time interval is first determined based on the start time and the first time, and a deadline having the same cross-sectional data as the start time is determined by continuously narrowing the time interval.
[0092] Exemplarily, taking the start time as the start time of the interval and the first time as the end time of the interval may include: if the first time is equal to the start time, determining a zipper record based on the start time and the first time; if the first time is greater than the start time, executing the start time as the start time of the interval and the first time as the end time of the interval.
[0093] In the disclosed embodiment, before determining the second time, it is possible to first determine whether the first time is equal to the start time. If so, it means that the first data only includes one zipper record to be repaired, and the start time, end time, and cross-section data corresponding to the start time can be used directly to repair the zipper record to be repaired.
[0094] The disclosed embodiment can quickly repair a zipper record whose start date is the start time and whose end date is the end time, thereby further shortening the repair time of the zipper record and improving the repair efficiency.
[0095] Step B2, determining the interval update time, wherein the interval update time is equal to the interval end time minus the interval start time divided by 2 and rounded plus the interval start time.
[0096] In the disclosed embodiment, the interval update time is used to continuously update the intermediate time between the interval start time or the interval end time of the time interval.
[0097] Step B3: if the section data of the interval update time is equal to the section data of the start time, the interval start time is set as the interval update time; otherwise, the interval end time is set as the interval update time.
[0098] In the disclosed embodiment, if the cross-sectional data of the interval update time is equal to the cross-sectional data of the start time, the interval start time of the time interval is updated, otherwise, the interval end time of the time interval is updated.
[0099] Step B4: if the difference between the interval end time and the interval start time is a unit time, the interval start time is determined to be the second time; otherwise, the step of determining the interval update time is executed cyclically.
[0100] In the embodiment of the present disclosure, when the difference between the end time of the interval and the start time of the interval is not equal to the unit time, the second time is quickly determined by cyclically executing the update steps (steps B2 and B3) until the difference between the end time of the interval and the start time of the interval is equal to the unit time, thereby further shortening the repair time of the zipper record and improving the repair efficiency.
[0101] In addition, since the embodiment of the present disclosure does not need to obtain and process cross-sectional data of all dates, the computing power of the electronic device is saved, making the operation of the electronic device more stable.
[0102] For example, Figure 3 As shown, for the sake of simplicity, the date is abbreviated in the embodiment of the present disclosure (for example, June 1 is written as June 1), the start time of the data to be repaired (for example, the first data) is June 1, the end time is June 30, and the first time is June 29. Among them, Rmin represents the start time of the interval, Rmax represents the end time of the interval, and E represents the interval update time. The process of determining the second time through the above exemplary embodiment is as follows.
[0103] 1) Comparing 6.1 and 6.29, the corresponding cross-sectional data 100≠500, among which, It should be noted that before determining the interval update time, the cross-sectional data at the start time may be compared with the cross-sectional data at the first time, which has the same function as determining whether the start time is the same as the first time.
[0104] 2) Comparing 6.1 and 6.15, the corresponding cross-sectional data is 100≠200, Rmax=E(6.15), where,
[0105] 3) Comparing 6.1 and 6.8, the corresponding cross-sectional data is 100=100, Rmin=E(6.8), where,
[0106] 4) Comparing 6.1 and 6.12, the corresponding cross-sectional data 100≠180, Rmax=E(6.12), where,
[0107] 5) Comparing 6.1 with 6.10, the corresponding cross-sectional data is 100≠180, Rmax=E(6.10), where,
[0108] 6) Comparing 6.1 with 6.9, the corresponding cross-sectional data are 100=100, Rmin=E(6.9), Rmax-Rmin=1.
[0109] When the difference between the interval end time and the interval start time is a unit time, the interval start time is determined to be the second time.
[0110] In yet another exemplary embodiment, calculating a second time between the start time and the first time based on a preset calculation rule, where the second time is a deadline having the same cross-sectional data as the start time, may include the following steps C1 to C4.
[0111] Step C1, taking the start time as the interval start time and the first time as the interval end time.
[0112] In the disclosed embodiment, a time interval is first determined based on the start time and the first time, and a deadline (ie, the second time) having the same cross-sectional data as the start time is determined by continuously narrowing the time interval.
[0113] Exemplarily, taking the start time as the start time of the interval and the first time as the end time of the interval may include: if the first time is equal to the start time, determining a zipper record based on the start time and the first time; if the first time is greater than the start time, executing the start time as the start time of the interval and the first time as the end time of the interval.
[0114] In the disclosed embodiment, before determining the second time, it is possible to first determine whether the first time is equal to the start time. If so, it means that the first data only includes one zipper record to be repaired, and the start time, end time, and cross-section data corresponding to the start time can be used directly to repair the zipper record to be repaired.
[0115] The disclosed embodiment can quickly repair a zipper record whose start date is the start time and whose end date is the end time, thereby further shortening the repair time of the zipper record and improving the repair efficiency.
[0116] Step C2, determining the interval update time, wherein the interval update time is equal to the interval end time minus the interval start time divided by 2 and rounded plus the interval start time.
[0117] In the disclosed embodiment, the interval update time is used to continuously update the intermediate time between the interval start time or the interval end time of the time interval.
[0118] Step C3, if the section data of the interval update time is equal to the section data of the start time, the interval start time is set as the interval update time, otherwise, the interval end time is set as the difference between the interval update time and the unit time.
[0119] In the embodiment of the present disclosure, if the cross-sectional data of the interval update time is equal to the cross-sectional data of the start time, the interval start time of the time interval is updated, otherwise, the interval end time of the time interval is updated. In the embodiment of the present disclosure, the interval end time is set to the difference between the interval update time and the unit time, so that the interval end time and the interval start time converge to be equal.
[0120] Step C4: if the interval end time is equal to the interval start time, the interval start time is determined to be the second time; otherwise, the interval update time determination step is executed cyclically.
[0121] In the embodiment of the present disclosure, when the interval end time is not equal to the interval start time, the steps of determining the interval update time (steps C2 and C3) are executed cyclically until the interval end time is equal to the interval start time.
[0122] In the disclosed embodiment, the second time is determined by a preset calculation rule, and when the interval end time is updated, the interval end time is updated by subtracting the unit time from the interval update time, so that the interval end time and the interval start time converge to be equal, so that the second time can be quickly determined. The repair time of the zipper record is further shortened, and the repair efficiency is improved.
[0123] In addition, since the embodiment of the present disclosure does not need to obtain and process cross-sectional data of all dates, the computing power of the electronic device is saved, making the operation of the electronic device more stable.
[0124] For example, Figure 4 As shown, for the sake of simplicity, the date is abbreviated in the embodiment of the present disclosure (for example, June 1 is written as June 1), the start time of the data to be repaired (for example, the first data) is June 1, the end time is June 30, and the first time is June 29. Among them, Rmin represents the start time of the interval, Rmax represents the end time of the interval, and E represents the interval update time. The process of determining the second time through the above exemplary embodiment is as follows.
[0125] 1) Comparing 6.1 and 6.29, the corresponding cross-sectional data 100≠500, among which, It should be noted that before determining the interval update time, the cross-sectional data at the start time may be compared with the cross-sectional data at the first time, which has the same function as determining whether the start time is the same as the first time.
[0126] 2) Comparing 6.1 and 6.15, the corresponding cross-sectional data is 100≠200, Rmax=E-1(6.14), where,
[0127] 3) Comparing 6.1 and 6.8, the corresponding cross-sectional data is 100=100, Rmin=E(6.8), where,
[0128] 4) Comparing 6.1 with 6.11, the corresponding cross-sectional data is 100≠180, Rmax=E-1(6.10), where,
[0129] 5) Comparing 6.1 with 6.9, the corresponding cross-sectional data is 100=100, Rmin=E(6.9), where,
[0130] 6) Comparing 6.1 with 6.10, the corresponding cross-sectional data is 100≠180, Rmax=E-1(6.9), where,
[0131] 7) Compare 6.1 with 6.9, the corresponding cross-sectional data 100=100, Rmin=Rmax, and determine the interval minimum time (6.9) as the second time. When the interval end time is equal to the interval start time, determine the interval minimum time as the second time.
[0132] In another exemplary embodiment, N=3, and a second time between the start time and the first time is determined based on the N division method, where the second time is the maximum time that has the same cross-sectional data as the start time, and can include: taking the start time as the interval start time and the first time as the interval end time; determining the interval update time, wherein the interval update time is equal to the interval end time minus the interval start time divided by 3 and rounded up plus the interval start time; if the cross-sectional data of the interval update time is equal to the cross-sectional data of the start time, then the interval start time is set to the interval update time, otherwise, the interval end time is set to the difference between the interval update time and the unit time; when the interval end time is equal to the interval start time, the interval start time is determined to be the second time; otherwise, the update step is executed in a loop.
[0133] The disclosed embodiment determines the second time based on the three-point method, and updates the interval end time by subtracting the unit time from the interval update time, so that the interval end time and the interval start time converge to be equal, thereby quickly determining the second time. This further shortens the repair time of the zipper record and improves the repair efficiency.
[0134] In addition, since the embodiment of the present disclosure does not need to obtain and process cross-sectional data of all dates, the computing power of the electronic device is saved, making the operation of the electronic device more stable.
[0135] In another exemplary embodiment, the present disclosure can also simultaneously use the 2-way division method and the M-way division method to determine the second time between the start time and the first time, where M is an integer greater than or equal to 3. For example, the second time is first determined by the 2-way division method and then by the 3-way division method. Since the early time interval is large, the 2-way division method can be used to quickly exclude the time interval that does not meet the requirements, and the 3-way division method is used to determine the second time when the later time interval is small (for example, the remaining time interval accounts for 10% of the total time interval). The present disclosure uses the 2-way division method and the M-way division method to determine the second time between the start time and the first time, and can quickly and accurately determine the second time, further shorten the repair time of the zipper record, and improve the repair efficiency.
[0136] It should be noted that the above exemplary embodiments of the present disclosure are applied in a zipper table with certain attributes, and the same data field value in the zipper table can only appear in continuous time intervals and cannot exist across time zones. For example, the loan resource information in the financial industry, the business characteristics determine that after a resource is loaned, the resource will only decrease as the resource is returned, and will not increase or decrease suddenly. The zipper table of fields with similar characteristics to the resources can be efficiently repaired using the method of the present disclosure. However, some business fields, such as the credit resources of the contract, are not suitable for the present disclosure. Because the credit resources will change in different periods, such as the data field value from 1000->5000->3000->1000, this kind of zipper table performance cannot use the method of the present disclosure to narrow the time interval range.
[0137] The above describes how to repair the first data. The following describes how to determine the start time and end time of the first data.
[0138] In an exemplary embodiment, the zipper table may include M zipper records, where M is an integer greater than or equal to 0, the first data includes at least one missing zipper record, and the zipper record may include section data, a start date, and an end date.
[0139] Before obtaining the start time and the end time of the first data of the zipper table, the method may further include S501.
[0140] S501, determine the start time and end time of the first data on the zipper table according to the creation date, the preset end date, and the start date and end date of the M zipper records on the zipper table, wherein the creation date is used to indicate the date on which the zipper table is created, and the preset end date is used to indicate the end date of the last zipper record on the zipper table.
[0141] Exemplarily, S501 may include steps D1 to D4.
[0142] Step D1, obtaining the start date and end date of M zipper records in the zipper table.
[0143] The zipper table in the disclosed embodiment is a zipper table to be repaired. The start date is the date when the zipper record starts. For example, start_dt in Table 2. The end date is the date when the zipper record ends. For example, end_dt in Table 2.
[0144] Step D2, obtaining a creation date, where the creation date is used to indicate the date when the zipper table is created.
[0145] In the embodiment of the present disclosure, the creation date (create_time) can be obtained from the original state table. Exemplarily, the original state table is shown in Table 3 below.
[0146] As shown in Table 3 below, the creation date is 2020-06-01. It should be noted that the starting date (the starting date of the first record of the complete zipper table) is confirmed. The zipper starting date is defined as the earliest section dt where the data appears. For example, Figure 1 As shown in the complete version of the zipper table, the earliest start_dt is 2020-06-01, so dt=2020-06-01 is the starting date of user A. In actual production applications, the zipper record that may be lost is the first row (that is, the record with start_dt=2020-06-01). If the starting date is determined only by the zipper table, the starting date information will be missing. Therefore, the confirmation of the starting date of the present disclosure requires the use of the original state table to find the create_time information. That is, get create_time from the original state table, such as create_time=2020-06-01 in Table 3, and use this as the starting date. (By comparing the starting date with the earliest and smallest start_dt in the zipper table, you can determine whether the first row of data in the zipper table is missing).
[0147] Table 3 Original state table
[0148] Time Section Account Resources Credit resources create_time 2020-06-01 1000 5000 2020-06-01 2020-06-02 1000 5000 2020-06-01 2020-06-03 1000 5000 2020-06-01 2020-06-04 1000 5000 2020-06-01 2020-06-05 1000 3000 2020-06-01 2020-06-06 1000 3000 2020-06-01 2020-06-07 500 3000 2020-06-01 2020-06-08 500 3000 2020-06-01 2020-06-09 500 3000 2020-06-01 2020-06-10 500 8000 2020-06-01 …… …… …… ……
[0149] Step D3, obtaining a preset end date, where the preset end date is used to indicate the end date of the last zipper record in the zipper table.
[0150] In the embodiment of the present disclosure, the preset end date is the end date. It can be obtained according to preset data, and can also be obtained through the latest valid state zipper. The valid state zipper is shown in Table 4 below.
[0151] Table 4 Effective state zipper
[0152]
[0153] The preset end date in Table 4 is 2099-12-31. It should be noted that the end date is determined. The determination of the end point is the data end_dt = 2099-12-31. This date is a common convention, which represents that the zipper data in this row is in a valid state at the latest time dt. As shown in Table 4, the meaning of this row of data is that from 2020-06-30 to an infinitely long time in the future (the end date), the valid data of A will take the record in this row. The infinitely far time is agreed here, that is, the preset end date in this disclosure is recorded as 2099-12-31 (some companies will agree on 9999-12-31 as the end point. There is no essential difference, as long as it is consistent before and after).
[0154] As described above, for each user, there is a row of data end_dt=2099-12-31, which is a valid state under the current dt. If the zipper table is detected without end_dt=2099-12-31, it means that the end zipper is missing.
[0155] Step D4, determining the start time and end time of the first data in the zipper table according to the creation date, the preset end date, and the start date and end date of the M zipper records in the zipper table.
[0156] In the embodiment of the present disclosure, if a zipper table is complete, it can be seen from the statistics of the start date and end date of each zipper record on the zipper table that, except for the start date of the first zipper record and the end date of the last zipper record, all dates are even numbers (such as 2). The present disclosure can make all dates on the complete zipper table even numbers by adding the creation date (i.e., the start date of the first zipper record) and the preset end date (the end date of the last zipper record). If the number of identical dates on the zipper table is an odd number (such as 1) after adding the creation date and the preset end date, it means that the zipper table is a zipper table with missing data and the zipper table needs to be repaired.
[0157] For example, Figure 6 As shown, Figure 6 Corresponding to the complete zipper table shown in Table 1, by adding the creation date 6.1 and the preset end date 12.31, the start date of the first zipper record and the end date of the last zipper record are supplemented with even numbers. It can be seen that after adding the creation date and the preset end date, the number of all identical dates in the complete zipper table is 2.
[0158] For example, Figure 7 As shown, Figure 7 Corresponding to the zipper table of missing data shown in Table 2, it can be seen that if there is a missing zipper table, then the number of times some points (dates) are projected (the number of times the same date occurs) is only 1 or 0. Therefore, as long as there is a point with a number of 1, it can be determined that the zipper table is missing.
[0159] The disclosed embodiment can quickly determine whether the zipper table is missing data by adding a creation date and a preset end date, and can determine the start time and end time of the first data on the zipper table based on the creation date, the preset end date, and the start date and end date of the M zipper records on the zipper table.
[0160] In one embodiment, determining the start time and end time of the first data on the zipper table based on the creation date, the preset end date, and the start date and end date of the M zipper records on the zipper table may include: obtaining two adjacent dates that do not have the same date based on the creation date, the preset end date, and the start date and end date of the M zipper records on the zipper table; and using the two adjacent dates that do not have the same date as the start time and end time of the first data, respectively.
[0161] In the embodiment of the present disclosure, after adding the creation date and the preset end date, if a zipper record is missing in the zipper table, two dates with a frequency of 1 will appear. If multiple consecutive zipper records are missing in the zipper table, two dates with a frequency of 1 will appear, and except for the start date of the first zipper record with a frequency of 1 and the end date of the last zipper record with a frequency of 1, the other dates with a frequency of 0 are all missing zipper records. In other words, the start date of the first zipper record of the missing zipper record is determined as the start time of the first data, and the end date of the last zipper record of the missing zipper record is determined as the end time of the first data. If only one zipper record is missing, the start date of the missing zipper record is determined as the start time of the first data, and the end date of the missing zipper record is determined as the end time of the first data.
[0162] It should be noted that, when the first data is a plurality of continuous zipper records, the two adjacent dates that do not have the same date are respectively the start date of the missing multiple continuous zipper records except the first zipper record and the end date of the last zipper record of the missing zipper record. Alternatively, when the first data is a zipper record, the two adjacent dates that do not have the same date are respectively the start date and the end date of the missing zipper record.
[0163] The disclosed embodiment can quickly determine whether the zipper table is missing data by adding a creation date and a preset end date, and use two adjacent dates that do not have the same date as the start time and end time of the first data, so as to quickly determine the time interval of the missing data.
[0164] In another embodiment, based on the creation date, the preset end date, and the start date and end date of M zipper records on the zipper table, obtaining two adjacent dates that do not have the same date can include: projecting the creation date, the preset end date, and the start date and end date of the M zipper records on the zipper table on a numerical axis to obtain two adjacent dates that do not have the same date.
[0165] For example, the number axis projection determines the number of times each date (also referred to as a point here) appears. Figure 6Take the complete zipper table in as an example, project the start_dt and end_dt of each row of the zipper table onto the number axis, and add the creation date and the preset end date on the number axis. These two dates can be used as the starting point and end point of the number axis. It can be seen that if the zipper data is not missing, each point will appear twice. Table 2 is a zipper table with missing data. According to the method disclosed in this disclosure, it is projected on the number axis, and the resulting number axis diagram is as follows: Figure 7 As shown in . The points with the number of occurrences of 1 are detected. Since the missing zipper records start_dt and end_dt do not participate in the projection at the same time, the number of points with the number of occurrences of 1 must be an even number, that is, they are matched in pairs. Figure 8 As shown, the missing zipper interval is the time range between two nodes with a number of occurrences of 1. Because they are paired in pairs, such as the two pairs of data connected by the dotted end, 6.5 and 6.10, and 6.17 and 6.26. So there are two missing intervals, [2020-6-5, 2020-6-10) and [2020-6-17, 2020-6-26). In other words, there are two data to be repaired, the first data and the second data, the start time and end time of the first data are 2020-6-5 and 2020-6-10 respectively. The start time and end time of the second data are 2020-6-17 and 2020-6-26 respectively.
[0166] It should be noted that the detected result interval (the time interval composed of the start time and end time of the data to be repaired) is a left-closed and right-open interval, that is, the right endpoint. Figure 8 The two dates 2020-6-10 and 2020-6-26 are not involved in the subsequent zipper record repair comparison, because the data of the two right endpoints have been used as the start_dt of the new zipper. For example, the second row of data start_dt = 2020-06-10 and the fourth row of data start_dt = 2020-06-26 in Table 2.
[0167] Abnormal missing data in zipper tables are usually random and unpredictable. Compared with ordinary tables, such as flow tables and status tables, zipper tables are more difficult to detect due to their unique data structure, and the recovery process is more complicated.
[0168] In the related art, when determining the interval of missing data in a zipper table, the cross-section time to be repaired is brought into the zipper table for calculation. Assuming that the cross-section to be repaired is denoted as dt, and dt = 2020-06-08, when calculating dt >= start_dt and dt < end_dt, it will be found that there is no record satisfying this condition, that is, when repairing the missing cross-section, the result obtained is empty. Therefore, if all missing zippers need to be detected, different times dt need to be brought into the zipper table for calculation one by one to know how many zipper records are missing. Obviously, this method has low detection efficiency and consumes a large amount of time. That is to say, in the related art, the corresponding cross-section data is restored through the zipper table. If it is found that the data is missing after restoration, it is determined that the data in the zipper table itself is missing, but this method has extremely low processing efficiency.
[0169] The present disclosure makes full use of the characteristics of the zipper table itself and the data of the existing table (such as the original state table), combines start_dt, end_dt, creation date and preset end date, and can achieve the goal of quickly detecting the missing interval through the projection method. Compared with the related art, the detection efficiency is improved.
[0170] It should be noted that different from the above zipper table repair, the method for determining the start time and end time of the first data in the present disclosure is applicable to zipper tables of any type and any business meaning. The method for determining the start time and end time of the first data in the present disclosure can quickly determine the time interval of the zipper record to be repaired.
[0171] The present disclosure makes full use of the characteristics of the zipper table records, combines the search method of binary search, and avoids the defect that a complete zipper table needs to be established by running batches day by day and calculating day by day. The repair efficiency of the zipper record is improved. Especially for the data to be repaired with a larger data volume and a longer time period, the efficiency improvement of the present disclosure is more obvious compared with the method in the related art. At the same time, since the present disclosure does not need to restore each cross-section by running batches day by day, the storage requirement is also reduced, and there is no need to calculate a large amount of data at the same time, which also saves the cluster memory resources.
[0172] Based on the same inventive concept, an embodiment of the present disclosure also provides a data processing device as described in the following embodiments. Since the principle of solving problems in this device embodiment is similar to that of the above method embodiment, the implementation of this system embodiment can refer to the implementation of the above method embodiment, and the repeated parts will not be described again.
[0173] Fig. 9 Show a schematic diagram of the data processing device in an embodiment of the present disclosure, as Fig. 9As shown, the data processing device may include an acquisition module 901 and a determination module 902. The acquisition module 901 may be used to acquire the start time and end time of the first data of the zipper table; the determination module 902 may be used to determine the first time based on the end time, where the first time is the difference between the end time and the unit time; the determination module 902 may also be used to calculate the second time between the start time and the first time based on a preset calculation rule, where the second time is the deadline for data with the same cross section as the start time; the determination module 902 may also be used to determine a zipper record of the first data based on the start time and the second time.
[0174] In one embodiment, after determining a zipper record of the first data based on the start time and the second time, the determination module 902 can also be used to calculate a fourth time between the third time and the first time based on a preset calculation rule when the third time is less than the first time, the fourth time being a deadline for having the same cross-sectional data as the third time, and the third time being the sum of the second time and the unit time; determine a zipper record based on the third time and the fourth time; and determine a zipper record based on the third time and the end time when the third time is equal to the first time.
[0175] In one embodiment, the determination module 902 can also be used to use the start time as the interval start time and the first time as the interval end time; determine the interval update time, wherein the interval update time is equal to the interval end time minus the interval start time divided by 2 and rounded up plus the interval start time; if the cross-sectional data of the interval update time is equal to the cross-sectional data of the start time, then the interval start time is set as the interval update time, otherwise, the interval end time is set as the interval update time; if the difference between the interval end time and the interval start time is a unit time, then the interval start time is determined to be the second time; otherwise, the step of determining the interval update time is executed in a loop.
[0176] In one embodiment, the determination module 902 can also be used to use the start time as the interval start time and the first time as the interval end time; determine the interval update time, wherein the interval update time is equal to the interval end time minus the interval start time divided by 2 and rounded up plus the interval start time; if the cross-sectional data of the interval update time is equal to the cross-sectional data of the start time, then the interval start time is set to the interval update time, otherwise, the interval end time is set to the difference between the interval update time and the unit time; if the interval end time is equal to the interval start time, then the interval start time is determined to be the second time; otherwise, the step of determining the interval update time is executed in a loop.
[0177] In one embodiment, the determination module 902 can also be used to determine a zipper record based on the start time and the first time if the first time is equal to the start time; if the first time is greater than the start time, the start time is used as the start time of the interval and the first time is used as the end time of the interval.
[0178] In one embodiment, the zipper table includes M zipper records, M is an integer greater than or equal to 0, the first data includes at least one missing zipper record, and the zipper record includes cross-sectional data, a start date, and an end date; wherein, before obtaining the start time and end time of the first data of the zipper table, the acquisition module 901 can also be used to determine the start time and end time of the first data on the zipper table based on the creation date, the preset end date, and the start date and end date of the M zipper records on the zipper table, wherein the creation date is used to indicate the date on which the zipper table is created, and the preset end date is used to indicate the end date of the last zipper record on the zipper table.
[0179] In one embodiment, the acquisition module 901 can also be used to obtain two adjacent dates that do not have the same date based on the creation date, the preset end date, and the start date and end date of the M zipper records in the zipper table; and use the two adjacent dates that do not have the same date as the start time and end time of the first data respectively.
[0180] In one embodiment, the acquisition module 901 may also be used to perform numerical axis projection on the creation date, the preset end date, and the start date and end date of the M zipper records on the zipper table to obtain two adjacent dates that do not have the same date.
[0181] The data processing device disclosed in the embodiment of the present disclosure determines the first time through the end time of the first data, and can quickly determine the end date of the data with the same cross-section as the start time based on a preset calculation rule, thereby determining a zipper record of the first data. The present disclosure simplifies the repair process of the zipper record, shortens the repair time of the zipper record, and improves the repair efficiency.
[0182] Those skilled in the art will appreciate that various aspects of the present disclosure may be implemented as systems, methods or program products. Therefore, various aspects of the present disclosure may be specifically implemented in the following forms, namely: complete hardware implementation, complete software implementation (including firmware, microcode, etc.), or a combination of hardware and software, which may be collectively referred to herein as "circuits", "modules" or "systems".
[0183] Refer to the following Fig.10 The electronic device 1000 according to this embodiment of the present disclosure is described. Fig.10The electronic device 1000 shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0184] like Fig.10 As shown, the electronic device 1000 is in the form of a general computing device. The components of the electronic device 1000 may include but are not limited to: the at least one processing unit 1010, the at least one storage unit 1020, and a bus 1030 connecting different system components (including the storage unit 1020 and the processing unit 1010).
[0185] The storage unit stores program codes, which can be executed by the processing unit 1010, so that the processing unit 1010 executes the steps described in the above “exemplary method” section of this specification according to various exemplary embodiments of the present disclosure.
[0186] The storage unit 1020 may include a readable medium in the form of a volatile storage unit, such as a random access storage unit (RAM) 10201 and / or a cache storage unit 10202 , and may further include a read-only storage unit (ROM) 10203 .
[0187] The storage unit 1020 may also include a program / utility 10204 having a set (at least one) of program modules 10205, such program modules 10205 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.
[0188] Bus 1030 may represent one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.
[0189] The electronic device 1000 may also communicate with one or more external devices 1040 (e.g., keyboards, pointing devices, Bluetooth devices, etc.), may also communicate with one or more devices that enable a user to interact with the electronic device 1000, and / or communicate with any device that enables the electronic device 1000 to communicate with one or more other computing devices (e.g., routers, modems, etc.). Such communication may be performed via an input / output (I / O) interface 1050. Furthermore, the electronic device 1000 may also communicate with one or more networks (e.g., local area networks (LANs), wide area networks (WANs), and / or public networks, such as the Internet) via a network adapter 1060. As shown, the network adapter 1060 communicates with other modules of the electronic device 1000 via a bus 1030. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device 1000, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.
[0190] Through the description of the above implementation, it is easy for those skilled in the art to understand that the example implementation described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (which can be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the implementation of the present disclosure.
[0191] In the disclosed exemplary embodiments, a computer-readable storage medium is also provided, which may be a readable signal medium or a readable storage medium. Fig.11 A schematic diagram of a computer-readable storage medium in an embodiment of the present disclosure is shown. Fig.11 As shown, the computer-readable storage medium 1100 stores a program product capable of implementing the above method of the present disclosure.
[0192] In some possible implementations, various aspects of the present disclosure may also be implemented in the form of a program product, which includes program code. When the program product is run on a terminal device, the program code is used to enable the terminal device to execute the steps of various exemplary implementations of the present disclosure described in the above "Specific Implementation Methods" section of this specification.
[0193] More specific examples of computer-readable storage media in the present disclosure may include, but are not limited to, an electrical connection having one or more conductors, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0194] In the present disclosure, a computer readable storage medium may include a data signal propagated in baseband or as part of a carrier wave, wherein a readable program code is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A readable signal medium may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.
[0195] Alternatively, the program code contained on the computer-readable storage medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the foregoing.
[0196] In a specific implementation, the program code for performing the operations of the present disclosure may be written in any combination of one or more programming languages, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as a separate software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., using an Internet service provider to connect through the Internet).
[0197] The embodiments of the present disclosure provide a computer program product or a computer program, which includes a computer instruction stored in a computer-readable storage medium. A processor of a computer device reads the computer instruction from the computer-readable storage medium, and the processor executes the computer instruction, so that the computer device executes the data processing method provided in various optional ways in any embodiment of the present disclosure.
[0198] It should be noted that, although several modules or units of the device for action execution are mentioned in the above detailed description, this division is not mandatory. In fact, according to the embodiments of the present disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. On the contrary, the features and functions of one module or unit described above can be further divided into multiple modules or units to be embodied.
[0199] Through the description of the above implementation, it is easy for those skilled in the art to understand that the example implementation described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (which can be a personal computer, a server, a mobile terminal, or a network device, etc.) to execute the method according to the implementation of the present disclosure.
[0200] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. The present disclosure is intended to cover any variations, uses or adaptations of the present disclosure, which follow the general principles of the present disclosure and include common knowledge or customary technical means in the art that are not disclosed in the present disclosure. The description and examples are to be regarded as exemplary only, and the true scope of the present disclosure is indicated by the appended claims.
Claims
1. A data processing method, characterized in that: include: Get the start time and end time of the first data in the zipper table; Determine a first time based on the end time, the first time being a difference between the end time and a unit time; Calculate a second time between the start time and the first time based on a preset calculation rule, the second time being a deadline having the same cross-sectional data as the start time; A zipper record of the first data is determined based on the start time and the second time.
2. The method according to claim 1, characterized in that: After determining a zipper record of the first data based on the start time and the second time, the method further includes: In the case where the third time is less than the first time, a fourth time between the third time and the first time is calculated based on a preset calculation rule, the fourth time being a deadline having the same cross-sectional data as the third time, and the third time being the sum of the second time and the unit time; Determine a zipper record based on the third time and the fourth time; When the third time is equal to the first time, a zipper record is determined based on the third time and the end time.
3. The method according to claim 1, characterized in that The calculating of a second time between the start time and the first time based on a preset calculation rule, wherein the second time is a deadline having the same cross-sectional data as the start time, comprises: Taking the start time as the interval start time and the first time as the interval end time; Determine an interval update time, wherein the interval update time is equal to the interval end time minus the interval start time divided by 2 and rounded plus the interval start time; If the cross-sectional data of the interval update time is equal to the cross-sectional data of the start time, the interval start time is set as the interval update time; otherwise, the interval end time is set as the interval update time; If the difference between the interval end time and the interval start time is the unit time, the interval start time is determined to be the second time; otherwise, the interval update time determination step is executed cyclically.
4. The method according to claim 1, characterized in that: The calculating of a second time between the start time and the first time based on a preset calculation rule, wherein the second time is a deadline having the same cross-sectional data as the start time, comprises: Taking the start time as the interval start time and the first time as the interval end time; Determine an interval update time, wherein the interval update time is equal to the interval end time minus the interval start time divided by 2 and rounded plus the interval start time; If the cross-sectional data of the interval update time is equal to the cross-sectional data of the start time, the interval start time is set to the interval update time; otherwise, the interval end time is set to the difference between the interval update time and the unit time; If the interval end time is equal to the interval start time, the interval start time is determined to be the second time; otherwise, the interval update time determination step is executed cyclically.
5. The method according to claim 3 or 4, characterized in that: The starting time is used as the interval start time, and the first time is used as the interval end time, including: If the first time is equal to the start time, determining a zipper record based on the start time and the first time; If the first time is greater than the start time, the start time is used as the interval start time and the first time is used as the interval end time.
6. The method according to claim 1, characterized in that The zipper table includes M zipper records, where M is an integer greater than or equal to 0, the first data includes at least one missing zipper record, and the zipper record includes the cross-section data, a start date, and an end date; Before obtaining the start time and end time of the first data of the zipper table, the method further includes: The start time and end time of the first data on the zipper table are determined based on the creation date, the preset end date, and the start date and end date of the M zipper records on the zipper table, wherein the creation date is used to indicate the date on which the zipper table is created, and the preset end date is used to indicate the end date of the last zipper record on the zipper table.
7. The method according to claim 6, characterized in that Determining the start time and end time of the first data on the zipper table according to the creation date, the preset end date, and the start date and end date of the M zipper records on the zipper table includes: Based on the creation date, the preset end date, and the start date and end date of the M zipper records in the zipper table, two adjacent dates are obtained; The two adjacent dates are respectively used as the start time and the end time of the first data.
8. The method according to claim 7, characterized in that Based on the creation date, the preset end date, and the start date and end date of the M zipper records in the zipper table, two adjacent dates are obtained, including: The creation date, the preset end date, and the start date and end date of the M zipper records in the zipper table are projected on a number axis to obtain two adjacent dates.
9. A data processing device, characterized in that: include: An acquisition module, used for acquiring the start time and end time of the first data of the zipper table; A determination module, configured to determine a first time based on the termination time, wherein the first time is a difference between the termination time and a unit time; The determination module is further used to calculate a second time between the start time and the first time based on a preset calculation rule, wherein the second time is a deadline having the same cross-sectional data as the start time; The determining module is further configured to determine a zipper record of the first data based on the start time and the second time.
10. An electronic device, characterized in that: include: processor; as well as A memory, configured to store executable instructions of the processor; The processor is configured to execute the data processing method according to any one of claims 1 to 8 by executing the executable instructions.
11. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the data processing method according to any one of claims 1 to 8 is implemented.
12. A computer program product, comprising a computer program or computer instructions, characterized in that: The computer program or the computer instruction is loaded and executed by a processor, so that the computer implements the data processing method according to any one of claims 1 to 8.