Data table updating method and device, equipment, storage medium and program product

By utilizing the indicator update time for incremental calculation of data tables in scenarios with long business lifecycles and multiple state updates, the problem of low data update efficiency and accuracy is solved, achieving efficient and accurate data updates.

CN121560896APending Publication Date: 2026-02-24BEIJING ZITIAO NETWORK TECH CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202511620761.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-06
Publication Date
2026-02-24

AI Technical Summary

Technical Problem

In scenarios with long business lifecycles and multiple state updates, the large amount of data updates leads to a large amount of computation, making it difficult to guarantee efficiency and accuracy.

Method used

By dividing the upstream raw data table into indicators with variable and immutable dimensions, the update amount of the target indicator is determined by the indicator update time, and incremental calculation is performed to avoid full calculation.

Benefits of technology

This reduces the order of magnitude of computing resources, improves the efficiency and accuracy of incremental metric updates, and reduces resource waste and metric discrepancies.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121560896A_ABST
    Figure CN121560896A_ABST
Patent Text Reader

Abstract

The invention discloses a data table updating method and device, equipment, a storage medium and a program product, and relates to the technical field of data processing, and the method comprises the steps: obtaining an upstream original data table and a downstream consumption index table corresponding to a target business scene, the upstream original data table comprises a plurality of first indexes with variable dimensions, a plurality of second indexes with immutable dimensions and index updating time; analyzing each index in the downstream consumption index table, and determining at least one target index of an immutable dimension; based on the index updating time in the upstream original data table, determining the index updating amount of each target index at the target specified moment; obtaining a previous moment corresponding to the target specified moment and a historical consumption index table corresponding to the previous moment; and updating the historical consumption index table based on the index update amount to obtain a target data table corresponding to the target specified moment. By implementing the method and the device, waste of computing resources is avoided, and the index increment updating efficiency and the data updating accuracy are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of data processing technology, specifically to methods, apparatus, devices, storage media, and program products for updating data tables. Background Technology

[0002] For scenarios with long business lifecycles, multiple state updates (such as hundreds of states), and long tail impacts on user experience (such as logistics business scenarios), the order of magnitude of data update volume is large, resulting in a large amount of computation for data updates, and it is difficult to guarantee data update efficiency and accuracy. Summary of the Invention

[0003] In view of this, the present disclosure provides a method, apparatus, device, storage medium, and program product for updating data tables to solve the problems of poor data update efficiency and accuracy.

[0004] Firstly, this disclosure provides a method for updating a data table, comprising: obtaining an upstream original data table and a downstream consumption indicator table corresponding to a target business scenario, wherein the upstream original data table includes a first indicator with multiple variable dimensions, a second indicator with multiple immutable dimensions, and indicator update time; parsing each indicator in the downstream consumption indicator table to determine at least one target indicator with immutable dimensions; determining the indicator update amount of each target indicator at a target specified time based on the indicator update time in the upstream original data table; obtaining the previous time corresponding to the target specified time and the historical consumption indicator table corresponding to the previous time; and updating the historical consumption indicator table based on the indicator update amount to obtain the target data table corresponding to the target specified time.

[0005] Secondly, this disclosure provides a data table updating device, comprising: a data acquisition module for acquiring an upstream original data table and a downstream consumption indicator table corresponding to a target business scenario, wherein the upstream original data table includes a first indicator with multiple variable dimensions, a second indicator with multiple immutable dimensions, and an indicator update time; a parsing module for parsing each indicator in the downstream consumption indicator table to determine multiple target indicators with immutable dimensions; an update quantity determination module for determining the indicator update quantity of each target indicator at a target specified time based on the indicator update time in the upstream original data table; a historical data acquisition module for acquiring the previous time corresponding to the target specified time and the historical consumption indicator table corresponding to the previous time; and a data update module for updating the historical consumption indicator table based on the indicator update quantity to obtain the target data table corresponding to the target specified time.

[0006] Thirdly, this disclosure provides an electronic device, including: a memory and a processor, which are communicatively connected to each other. The memory stores computer instructions, and the processor executes the computer instructions to perform the data table update method described in the first aspect or any corresponding embodiment.

[0007] Fourthly, this disclosure provides a computer-readable storage medium storing computer instructions for causing a computer to execute the data table update method described in the first aspect or any corresponding embodiment.

[0008] Fifthly, this disclosure provides a computer program product, including computer instructions for causing a computer to execute the data table update determination method described in the first aspect or any corresponding embodiment.

[0009] The data table update method, apparatus, device, storage medium, and program product provided in this disclosure divide the upstream original data table into a first indicator with variable dimensions, multiple second indicators with immutable dimensions, and indicator update time. By parsing each indicator in the downstream consumption indicator table, at least one target indicator with immutable dimensions in the downstream consumption indicator table is determined. Since the immutable dimensions do not change throughout the entire business lifecycle, the indicator update time in the upstream original data table can be used to determine the indicator update amount of each target indicator at a specified target time. This allows for incremental indicator calculation using the indicator update amount, avoiding resource waste from full-scale calculation. Subsequently, the indicator update amount is used to update the historical consumption indicator table at the previous time point at the specified target time. This allows for incremental indicator updates based on differences in downstream consumption scenarios, significantly reducing the order of magnitude of computation, decreasing incremental calculation time, and improving the efficiency of incremental indicator updates. Simultaneously, using target indicators with immutable dimensions for incremental indicator updates avoids indicator discrepancies, greatly improving data update accuracy. Attached Figure Description

[0010] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0011] Figure 1 This is a schematic diagram illustrating an application scenario according to an embodiment of this disclosure; Figure 2 This is a flowchart illustrating a method for updating a data table according to an embodiment of the present disclosure; Figure 3 This is a flowchart illustrating another data table update method according to an embodiment of the present disclosure; Figure 4 This is a flowchart illustrating another data table update method according to an embodiment of the present disclosure; Figure 5 This is a structural block diagram of a data table updating apparatus according to an embodiment of the present disclosure; Figure 6 This is a schematic diagram of the hardware structure of an electronic device according to an embodiment of the present disclosure. Detailed Implementation

[0012] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0013] It is understood that before using the technical solutions disclosed in the various embodiments of the present invention, users should be informed of the types, scope of use, and usage scenarios of the personal information involved in the present invention and their authorization should be obtained in accordance with relevant laws and regulations through appropriate means.

[0014] For example, upon receiving a user's active request, a prompt message is sent to the user to explicitly inform them that the requested operation will require the acquisition and use of the user's personal information. This allows the user to independently choose whether to provide personal information to the software or hardware, such as the electronic device, application, server, or storage medium performing the operations of this disclosed technical solution, based on the prompt message.

[0015] As an optional but non-limiting implementation, in response to a user's active request, sending a prompt message to the user can be done via a pop-up window, where the prompt message can be presented in text format. Furthermore, the pop-up window can also include a selection control allowing the user to choose "agree" or "disagree" to provide personal information to the electronic device.

[0016] It is understood that the above notification and user authorization process are merely illustrative and do not constitute a limitation on the implementation of this disclosure. Other methods that comply with relevant laws and regulations may also be applied to the implementation of this disclosure.

[0017] It is understood that the data involved in this technical solution (including but not limited to the data itself, the acquisition or use of the data) shall comply with the requirements of relevant laws, regulations and related provisions.

[0018] The terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of this invention, "a plurality of" means two or more, unless otherwise explicitly specified.

[0019] In logistics scenarios, the lifecycle of a package from creation to completion is relatively long, and there are some extremely long-tailed packages, such as those affected by force majeure events, which can cause the fulfillment / completion cycle to become very long. For scenarios with long business lifecycles, multiple state updates (such as hundreds of states), and long-tailed packages that impact user experience, current metric calculations generally use full data or truncation based on a certain time window (such as using the creation time to truncate the most recent 180 days).

[0020] However, due to the complexity of incremental calculations for metrics and the large order of magnitude of data updates, a full-scale calculation approach would waste 99% of computational resources, as only about 1% of packages have status updates each day. While processing by time window segmentation reduces redundant calculations to some extent, it misses extremely long-tail packages exceeding the time window, leading to incomplete metric calculations. This is particularly problematic for observing long-tail metrics, as the missing data cannot be observed, resulting in a poor user experience.

[0021] Based on this, the technical solution disclosed herein determines the indicator dimensions and indicator data that need to be recalculated according to the currently updated data and downstream consumption scenarios, thereby realizing incremental calculation of the affected indicators. While ensuring that the incremental calculation results are consistent with the full calculation results, it greatly reduces the order of magnitude of computing resources, avoids the waste of resources under full calculation, and improves the efficiency of incremental indicator updates and the accuracy of data updates.

[0022] As one optional application scenario of this disclosure embodiment, such as Figure 1 As shown, the optional application scenario includes electronic device 101, business scenario database 102, and data processing platform 103. The business scenario database 102 stores data tables generated under the business scenario, and the business scenario database 102 communicates with the electronic device 101. This communication connection can be a wired network or a wireless network, examples of which include, but are not limited to, the Internet, corporate intranet, local area network, wide area network, mobile communication network, and combinations thereof.

[0023] The data processing platform 103 is deployed in the electronic device 101. It is used to input the target specified time through the interactive page displayed on the electronic device 101, so that the data processing platform 103 can determine the currently updated data from the business scenario database 102 according to the target specified time, and determine the indicator dimensions and indicator data that need to be recalculated according to the currently updated data and the downstream consumption scenario, so as to realize the incremental update of indicators.

[0024] The electronic device 101 can be a device with computing capabilities. For example, it may include a processor and memory, and may also be equipped with a dedicated accelerator (such as a graphics processing unit (GPU)). Furthermore, the electronic device can store and maintain data. Examples of electronic devices may include supercomputers, personal computers, laptops, in-vehicle computing devices, mobile devices (such as smartphones, tablets, etc.), or combinations thereof. It should be understood that the electronic device described herein is merely exemplary and not limiting; other different types of electronic devices may also be used.

[0025] According to an embodiment of this disclosure, a method for updating a data table is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.

[0026] This embodiment provides a method for updating a data table, which can be used in the aforementioned electronic devices, such as computers. Figure 2 This is a flowchart of a data table update method according to an embodiment of the present disclosure, such as... Figure 2 As shown, the process includes the following steps: Step S201: Obtain the upstream raw data table and downstream consumption indicator table corresponding to the target business scenario. The upstream raw data table includes a first indicator with multiple variable dimensions, a second indicator with multiple immutable dimensions, and the indicator update time.

[0027] The target business scenario is one with a long lifecycle and multiple state indicator changes, such as a logistics business scenario. The upstream raw data table is a data table generated for the indicators required by the target business scenario. The downstream consumption indicator table is a data table determined by the target business scenario in the downstream consumption process. The downstream consumption indicator table is generated by aggregating the upstream raw data table according to the corresponding indicator dimensions. Specifically, the upstream raw data table and the downstream consumption indicator table can be read from the database corresponding to the target business scenario.

[0028] As shown in Table 1, the upstream original data table includes multiple variable-dimensional first indicators, multiple immutable-dimensional second indicators, and indicator update times. Each variable-dimensional first indicator, each immutable-dimensional second indicator, and indicator update time have corresponding data columns in the upstream original data table.

[0029] The first metric's value may change throughout the business lifecycle, such as the delivery person's information or the estimated delivery time (which may involve multiple deliveries). The second metric's value remains unchanged throughout the business lifecycle, such as the package creation time or delivery address. The metric update time indicates the most recent update time of the metric data. Of course, a primary key is also set in the upstream raw data table to uniquely identify each object in the upstream raw data table; for example, the same package has the same package identifier ID.

[0030] Table 1. Upstream Raw Data Table

[0031] Among them, C1 to Cj are the first indicators of the variable dimension; K1 to Ki are the second indicators of the immutable dimension; the lduts column indicates the most recent update time of the data, that is, the indicator update time.

[0032] The downstream consumption indicator table can be generated by aggregating the upstream raw data table according to the corresponding indicator dimensions. For example, the downstream consumption indicator table can be generated by aggregating the immutable dimensions K1 and K2 and the variable dimension C1, as shown in Table 2.

[0033] Table 2 Downstream Consumption Indicators

[0034] The total number of rows is N; Value represents the aggregation result, which can be obtained by counting; K1 / K2 are immutable dimensions, which are generated from the upstream original data table according to the corresponding indicator dimensions.

[0035] Step S202: Analyze each indicator in the downstream consumption indicator table and determine at least one target indicator of the immutable dimension.

[0036] Since the downstream consumption indicator table is generated based on the downstream data consumption situation, by analyzing the indicator data of each indicator in the downstream consumption indicator table and combining the consumption situation of the indicator data, we can determine multiple indicators in the downstream consumption indicator table that will not change, that is, multiple target indicators with immutable dimensions.

[0037] Using Table 2 from the previous example, by analyzing each indicator in the downstream consumption indicator table, we can determine the invariable dimension indicators K1 and K2.

[0038] Step S203: Based on the indicator update time in the upstream original data table, determine the indicator update amount of each target indicator at the specified target time.

[0039] The target specified time is the time when incremental updates of metrics need to be performed, such as the current time T. The metric update amount represents the metric data that has changed in the upstream original data table at the target specified time. Specifically, the upstream original data table updates its data according to the business execution status of the target business scenario, and a corresponding metric update time is set for each data update. Once the target specified time is determined, the metric update time in the upstream original data table is compared with the target specified time to obtain the metric update amount at the target specified time from the upstream original data table.

[0040] Using Table 1 from the previous example, for instance, if the target specified time is t1, by comparing the indicator update time in the upstream original data table with the target specified time, the indicator update amount at the target specified time can be determined, as shown in Table 3.

[0041] Table 3 Indicator Update Volume

[0042] It should be noted that the row data corresponding to update time t0 is the data updated after the incremental update at the time before the target specified time t1. Therefore, when extracting the indicator update amount at the target specified time t1, it is also necessary to obtain the incremental data to ensure the integrity of the incremental data.

[0043] Step S204: Obtain the previous time corresponding to the specified time of the target and the historical consumption index table corresponding to the previous time.

[0044] The previous time point refers to the most recent time before the target specified time point when the indicator increment calculation was performed; the historical consumption indicator table is the consumption indicator table generated by the indicator increment calculation at the previous time point. Specifically, the consumption indicators generated by the indicator increment calculation at each time point are stored in the database. The target specified time point is compared with the historical time points of the indicator increment calculation to determine the previous time point corresponding to the target specified time point, and the historical consumption indicator table corresponding to that previous time point is retrieved from the database.

[0045] Step S205: Update the historical consumption indicator table based on the indicator update amount to obtain the target data table corresponding to the specified target time.

[0046] The target data table is a consumption indicator table generated by updating the indicator data. Specifically, the indicator update amount corresponding to the target specified time obtained from the upstream original data table is updated to the corresponding position in the historical consumption indicator table. The indicator update amount is used to update the aggregated results in the historical consumption indicator table to obtain a new consumption indicator table, that is, the target data table at the target specified time.

[0047] The data table update method provided in this embodiment divides the upstream original data table into a first indicator with variable dimensions, multiple second indicators with immutable dimensions, and indicator update time. By parsing each indicator in the downstream consumption indicator table, at least one target indicator with immutable dimensions in the downstream consumption indicator table is determined. Since the immutable dimensions do not change throughout the entire business lifecycle, the indicator update time in the upstream original data table can be used to determine the indicator update amount of each target indicator at the target specified time. This allows for incremental indicator calculation using the indicator update amount, avoiding resource waste from full-scale calculation. Subsequently, the indicator update amount is used to update the historical consumption indicator table at the previous time point at the target specified time. This allows for incremental indicator updates based on differences in downstream consumption scenarios, significantly reducing the order of magnitude of computation, decreasing incremental calculation time, and improving the efficiency of incremental indicator updates. Simultaneously, using target indicators with immutable dimensions for incremental indicator updates avoids indicator discrepancies, greatly improving data update accuracy.

[0048] This embodiment provides a method for updating a data table, which can be used in the aforementioned electronic devices, such as computers. Figure 3 This is a flowchart of a data table update method according to an embodiment of the present disclosure, such as... Figure 3 As shown, the process includes the following steps: Step S301: Obtain the upstream raw data table and downstream consumption indicator table corresponding to the target business scenario. The upstream raw data table includes a first indicator with multiple variable dimensions, a second indicator with multiple immutable dimensions, and the indicator update time. For details, please refer to the relevant descriptions of the corresponding steps in the above embodiments, which will not be repeated here.

[0049] Step S302: Analyze each indicator in the downstream consumption indicator table and determine at least one target indicator of the immutable dimension.

[0050] Specifically, step S302 includes: Step S3021: Analyze each indicator in the downstream consumption indicator table and determine the corresponding indicator data for each indicator.

[0051] Indicator data refers to the consumption data corresponding to each indicator. Specifically, each indicator has a corresponding data column in the downstream consumption indicator table. By parsing each indicator in the downstream consumption indicator table, the position of each indicator in the table can be determined. Then, based on the indicator position, the indicator data matching each indicator can be extracted from the downstream consumption indicator table.

[0052] Step S3022: Based on the consumption status of the indicator data, extract at least one target indicator with an immutable dimension from each indicator in the downstream consumption indicator table.

[0053] Consumption status is used to characterize the use of indicator data. Specifically, indicator data in a variable dimension can change along with the consumption status, while indicator data in an immutable dimension will not change with the consumption status. Therefore, by combining the consumption status corresponding to each indicator data, one or more target indicators in the immutable dimension of the downstream consumption indicator table can be determined.

[0054] In some optional implementations, step S3022 above includes: Step a1: Obtain multiple third indicators of immutable dimensions extracted from the downstream consumption indicator table.

[0055] Step a2: Based on the indicator dimension corresponding to the third indicator, aggregate multiple third indicators to obtain at least one target indicator.

[0056] By combining the consumption status corresponding to each indicator data, one or more indicators with immutable dimensions are extracted from the downstream consumption indicator table, i.e., the third indicators. The indicator dimension is used to characterize whether multiple third indicators have the same dimension. If two third indicators have the same indicator dimension, it means that these two third indicators are the same indicator.

[0057] Therefore, when there are multiple third indicators, the same third indicators can be aggregated into one indicator according to the indicator dimension. Thus, by aggregating multiple third indicators according to the indicator dimension, one or more target indicators can be obtained.

[0058] In the above implementation, by extracting multiple third indicators with immutable dimensions from the downstream consumption indicator table, and aggregating the multiple third indicators according to the indicator dimensions corresponding to the third indicators, one or more target indicators can be obtained. Thus, the target indicators of the immutable consumption dimensions can be clearly defined according to the consumption scenarios of the downstream consumption indicator table, so as to calculate the indicator increment according to the target indicators, reduce the amount of indicator increment calculation, avoid indicator differences, and make the data more accurate.

[0059] Step S303: Based on the indicator update time in the upstream original data table, determine the indicator update amount of each target indicator at the specified target time.

[0060] Specifically, step S303 includes: Step S3031: Based on the indicator update time in the upstream original data table, obtain the amount of data change in the upstream original data table at the target specified time.

[0061] Data change volume represents the data changes that occurred in the upstream original data table at the target specified time. Since the indicator update time represents the data update time in the upstream original data table, the data change volume of the upstream original data table at the target specified time can be obtained by comparing the indicator update time in the upstream original data table with the target specified time.

[0062] In some optional implementations, step S3031 above includes: Step b1: Compare the update times of each indicator in the upstream original data table with the target specified time to determine the amount of target data whose indicator update time is the same as the target specified time.

[0063] Step b2: Determine the target data volume as the data change volume.

[0064] Specifically, the update time of each indicator in the upstream original data table is compared with the target specified time to determine the target data volume when the indicator update time is the target specified time, and this target data volume is determined as the data change volume at the target specified time.

[0065] In the above implementation, the amount of data change is determined by comparing the indicator update time with the target specified time, avoiding the indicator differences caused by truncating data according to a fixed time window. This avoids the impact of long-tail scenarios on business indicators, prevents indicator calculation omissions, and further improves data accuracy.

[0066] Step S3032: Based on the data change volume and the data consumption logic corresponding to the downstream consumption indicator table, determine the indicator update volume corresponding to each target indicator.

[0067] Data consumption logic involves reading, processing, and using data from the downstream consumption indicator table, such as data querying, data aggregation calculation, data transformation, and data access. Based on the data consumption logic corresponding to the downstream consumption indicator table, the indicator data corresponding to each target indicator in the downstream consumption indicator table is updated and calculated according to the data change volume to obtain the indicator update volume for each target indicator.

[0068] In some optional implementations, step S3032 above includes: Step c1: Based on the correlation between the data change volume and each target indicator, obtain the associated change volume corresponding to each target indicator.

[0069] Step c2: Based on the data consumption logic corresponding to the downstream consumption indicator table, obtain the indicator update volume generated by each target indicator under the associated change volume.

[0070] The target indicators determined from the downstream consumption indicator table are associated with the upstream original data table at the specified target time to obtain the correlation between the data change volume and each target indicator, and the associated change volume corresponding to the target indicator is filtered out from the data change volume according to the correlation.

[0071] Subsequently, based on the data consumption logic corresponding to the downstream consumption indicator table, the indicator data in the downstream consumption indicator table are recalculated according to the associated change amount to obtain the indicator update amount of each target indicator in the downstream consumption indicator table under the associated change amount.

[0072] In the above implementation, the update volume of indicators in the downstream consumption indicator table is calculated according to the data change volume and the associated change volume of the target indicator. This allows for a comprehensive calculation of all changed data, thereby achieving a comprehensive observation of all changed data, ensuring the comprehensiveness of data updates, and improving the user experience of the data table.

[0073] Step S304: Obtain the previous time step corresponding to the specified target time step and the historical consumption index table corresponding to the previous time step. For details, please refer to the relevant descriptions of the corresponding steps in the above embodiments, which will not be repeated here.

[0074] Step S305: Update the historical consumption indicator table based on the indicator update amount to obtain the target data table corresponding to the specified time. For details, please refer to the relevant descriptions of the corresponding steps in the above embodiments, which will not be repeated here.

[0075] The data table update method provided in this embodiment parses the downstream consumption indicator table to determine the indicator data corresponding to each indicator, and extracts the immutable target indicator from each indicator in the downstream consumption indicator table in combination with the consumption status of the indicator data. The indicator increment is calculated according to the target indicator. Since the target indicator is unchanged throughout the entire business lifecycle, the data level of the calculation can be greatly reduced, and the efficiency of indicator increment calculation can be improved.

[0076] By combining the indicator update time in the upstream original data table, the amount of data change at the target specified time is obtained. Based on the amount of data change and the data consumption logic corresponding to the downstream consumption indicator table, the indicator update amount corresponding to each target indicator is determined. In this way, the indicator update amount of the target indicator of the immutable dimension can be accurately calculated, thus improving the accuracy of indicator update.

[0077] This embodiment provides a method for updating a data table, which can be used in the aforementioned electronic devices, such as computers. Figure 4 This is a flowchart of a data table update method according to an embodiment of the present disclosure, such as... Figure 4 As shown, the process includes the following steps: Step S401: Obtain the upstream raw data table and downstream consumption indicator table corresponding to the target business scenario. The upstream raw data table includes a first indicator with multiple variable dimensions, a second indicator with multiple immutable dimensions, and the indicator update time. For details, please refer to the relevant descriptions of the corresponding steps in the above embodiments, which will not be repeated here.

[0078] Step S402: Analyze each indicator in the downstream consumption indicator table to determine multiple target indicators with immutable dimensions. For details, please refer to the relevant descriptions of the corresponding steps in the above-described embodiments; they will not be repeated here.

[0079] Step S403: Based on the indicator update time in the upstream original data table, determine the indicator update amount of each target indicator at the specified target time. For details, please refer to the relevant descriptions of the corresponding steps in the above-described embodiments, which will not be repeated here.

[0080] Step S404: Obtain the previous time step corresponding to the specified target time step and the historical consumption index table corresponding to the previous time step. For details, please refer to the relevant descriptions of the corresponding steps in the above embodiments, which will not be repeated here.

[0081] Step S405: Update the historical consumption indicator table based on the indicator update amount to obtain the target data table corresponding to the specified target time.

[0082] Specifically, step S405 includes: Step S4051: Obtain the historical indicator quantity corresponding to each target indicator in the historical consumption indicator table.

[0083] Historical indicator quantities are the corresponding indicator quantities of the target indicator in the historical consumption indicator table. Specifically, as described above, the historical consumption indicator table is the consumption indicator table at the time preceding the specified target time. For example, if the specified target time is T, then the historical consumption indicator table is the consumption indicator table obtained at time T-1. Therefore, by analyzing multiple indicators in the historical consumption indicator table, the target indicator can be determined from multiple indicators. Subsequently, the indicator data corresponding to the position of each target indicator is extracted, and the indicator data corresponding to the target indicator is determined as the historical indicator quantity.

[0084] Step S4052: Update the historical index values ​​using the index update values ​​to obtain the target data table at the specified time.

[0085] The historical indicators in the historical consumption indicator table are updated accordingly by updating the indicator update amount, and the historical consumption indicator table is updated to the consumption indicator table at the target specified time. The updated consumption indicator table is then determined as the target data table.

[0086] In some optional implementations, step S4052 above includes: Step d1: Delete the historical indicator quantities from the historical consumption indicator table to obtain the consumption indicator adjustment table.

[0087] Step d2: Merge the indicator update volume with the consumption indicator adjustment table to generate the target data table.

[0088] Since historical metrics are unchanged, the corresponding historical metrics for the target metric can be deleted from the historical consumption metric table, resulting in a corresponding consumption metric adjustment table. Then, the updated metrics are merged with the remaining metrics in the consumption metric adjustment table to generate a new consumption metric table, i.e., the target data table. This allows for direct updates to the metrics in the historical consumption metric table, reducing the intrusion of incremental calculations into the business logic and lowering the overall update cost of the data table.

[0089] The data table update method provided in this embodiment obtains the historical indicator quantity corresponding to each target indicator in the historical consumption indicator table, and updates the historical indicator quantity using the indicator update quantity, thereby obtaining the target data table at the specified time. This allows for direct updating of the historical consumption indicator table to generate the target data table. The data update method is simple and universal, enhancing its applicability for indicator calculation in business scenarios with long business lifecycles and multiple state changes.

[0090] As a specific application embodiment of this disclosure, the above method is described as follows, in conjunction with a package details table in a logistics business scenario: (1) Obtain the package details table raw_table(T time) at the specified time of the target (time T, such as time T = 2025-08-01), as shown in Table 4.

[0091] Table 4 Package Details Table (at time T)

[0092] (2) Obtain the average delivery time of the package at the time before the target specified time - metrics_table (time T-1), as shown in Table 5.

[0093] Table 5 Average Parcel Delivery Time - Metrics Table (Time T-1)

[0094] (3) Extract the target index K_table of the immutable dimension from the downstream consumption index table, as shown in Table 6.

[0095] Table 6 Target Indicator K_table (Time T)

[0096] (4) Use K_table to associate with raw_table (time T) to obtain the data raw_table_recal (time T) that needs to be recalculated in the current update, as shown in Table 7.

[0097] Table 7 raw_table_recal (time T)

[0098] (5) Calculate the update amount of metrics_table according to the consumption logic of metrics_table, denoted as metrics_table_inc(time T), as shown in Table 8.

[0099] Table 8 metrics_table_inc (time T)

[0100] (6) Exclude the data from K_table (time T) from metrics_table (time T-1) and merge metrics_table_inc (time T) to generate a new metrics_table (time T), as shown in Table 9.

[0101] Table 9 metrics_table (time T)

[0102] Thus, the data table update method disclosed herein avoids the discrepancies in metrics caused by truncation within a fixed time window; thereby preventing the impact of long-tail scenarios on business metrics, resulting in more accurate data, better suited for metric calculation in business scenarios with long lifecycles and multiple state changes, a simple and universal architecture, low intrusion of incremental calculations into business logic, and relatively low overall upgrade costs. Simultaneously, it avoids the resource waste of full-scale calculations; and the order of magnitude of computation is significantly reduced according to the differences in downstream consumption scenarios.

[0103] This embodiment also provides a table updating device for implementing the above embodiments and preferred embodiments; details already described will not be repeated. As used below, the term "module" can be a combination of software and / or hardware that implements a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.

[0104] This embodiment provides a table updating device, such as... Figure 5 As shown, it includes: The data acquisition module 501 is used to acquire the upstream raw data table and the downstream consumption indicator table corresponding to the target business scenario. The upstream raw data table includes a first indicator with multiple variable dimensions, a second indicator with multiple immutable dimensions, and the indicator update time.

[0105] The parsing module 502 is used to parse the various indicators in the downstream consumption indicator table and determine at least one target indicator of the immutable dimension.

[0106] The update quantity determination module 503 is used to determine the update quantity of each target indicator at a specified time based on the indicator update time in the upstream original data table.

[0107] The historical data acquisition module 504 is used to acquire the previous time corresponding to the specified time of the target and the historical consumption index table corresponding to the previous time.

[0108] The data update module 505 is used to update the historical consumption indicator table based on the indicator update amount to obtain the target data table corresponding to the specified target time.

[0109] In some alternative implementations, the parsing module 502 includes: The indicator data determination unit is used to parse the various indicators in the downstream consumption indicator table and determine the corresponding indicator data for each indicator.

[0110] The target indicator extraction unit is used to extract at least one target indicator of an immutable dimension from each indicator in the downstream consumption indicator table based on the consumption status of indicator data.

[0111] In some optional implementations, the target indicator extraction unit includes: The indicator acquisition subunit is used to acquire multiple third indicators of immutable dimensions extracted from the downstream consumption indicator table.

[0112] The indicator aggregation subunit is used to aggregate multiple third indicators based on the indicator dimension corresponding to the third indicator to obtain at least one target indicator.

[0113] In some optional implementations, the update amount determination module 503 includes: The data change acquisition unit is used to acquire the data change volume of the upstream original data table at a target specified time based on the indicator update time in the upstream original data table.

[0114] The indicator update quantity determination unit is used to determine the indicator update quantity for each target indicator based on the data change quantity and the data consumption logic corresponding to the downstream consumption indicator table.

[0115] In some optional implementations, the data change acquisition unit includes: The data comparison subunit is used to compare the update time of each indicator in the upstream original data table with the target specified time to determine the amount of target data whose indicator update time is the same as the target specified time.

[0116] The change quantity determination subunit is used to determine the target data quantity as the data change quantity.

[0117] In some optional implementations, the above-mentioned indicator update determination unit includes: The correlation sub-unit is used to obtain the correlation change volume corresponding to each target indicator based on the correlation between the data change volume and each target indicator.

[0118] The change volume generation subunit is used to obtain the indicator update volume generated under the associated change volume for each target indicator based on the data consumption logic corresponding to the downstream consumption indicator table.

[0119] In some alternative implementations, the data update module 505 includes: The historical indicator acquisition unit is used to obtain the historical indicator quantity corresponding to each target indicator in the historical consumption indicator table.

[0120] The update unit is used to update historical indicator values ​​using the indicator update amount to obtain the target data table at the specified time.

[0121] In some optional implementations, the above-mentioned updating unit includes: The delete sub-cell is used to delete historical indicator quantities from the historical consumption indicator table to obtain the consumption indicator adjustment table.

[0122] The merge sub-unit is used to merge the indicator update volume with the consumption indicator adjustment table to generate the target data table.

[0123] The table updating apparatus provided in this disclosure can execute the table updating method provided in any embodiment of this disclosure, and has the corresponding functional modules and beneficial effects of executing the method.

[0124] The upstream raw data table is divided into a first indicator with variable dimensions, multiple second indicators with immutable dimensions, and indicator update time. By analyzing each indicator in the downstream consumption indicator table, at least one target indicator with immutable dimensions is identified. Since the immutable dimensions do not change throughout the business lifecycle, the indicator update time in the upstream raw data table can be used to determine the indicator update amount of each target indicator at a specified target time. This update amount is then used for incremental indicator calculation, avoiding the resource waste of full-scale calculation. Subsequently, the indicator update amount is used to update the historical consumption indicator table at the previous time point. This allows for incremental indicator updates based on differences in downstream consumption scenarios, significantly reducing the computational load and incremental calculation time, and improving the efficiency of incremental indicator updates. Furthermore, using the target indicator with immutable dimensions for incremental indicator updates avoids indicator discrepancies, greatly improving data update accuracy.

[0125] Further functional descriptions of the above modules and units are the same as those in the corresponding embodiments described above, and will not be repeated here.

[0126] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this disclosure.

[0127] The following is a detailed reference. Figure 6 This diagram illustrates a suitable structural schematic for implementing an electronic device according to embodiments of the present disclosure. The electronic device may include a processor (e.g., a central processing unit, graphics processor, etc.) 601, which can perform various appropriate actions and processes based on a program stored in read-only memory (ROM) 602 or a program loaded from memory 608 into random access memory (RAM) 603. The RAM 603 also stores various programs and data required for the operation of the electronic device. The processor 601, ROM 602, and RAM 603 are interconnected via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.

[0128] Typically, the following devices can be connected to I / O interface 605: input devices 606 including, for example, touchscreens, touchpads, keyboards, mice, cameras, microphones, accelerometers, gyroscopes, etc.; output devices 607 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; memory devices 608 including, for example, magnetic tapes, hard disks, etc.; and communication devices 609. Communication device 609 allows electronic devices to communicate wirelessly or wiredly with other devices to exchange data. Although Figure 6 Electronic devices with various devices are shown, but it should be understood that it is not required to implement or have all of the devices shown, and more or fewer devices may be implemented or have instead.

[0129] In particular, according to embodiments of this disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of this disclosure include a computer program product comprising a computer program carried on a non-transitory computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device 609, or installed from a memory 608, or installed from a ROM 602. When the computer program is executed by the processor 601, it performs the functions defined in the table update method of embodiments of this disclosure.

[0130] Figure 6 The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of the embodiments disclosed herein.

[0131] This disclosure also provides a computer-readable storage medium in which the methods described in this disclosure can be implemented in hardware or firmware, or implemented as recordable on a storage medium, or implemented as computer code originally stored on a remote storage medium or a non-transitory machine-readable storage medium and subsequently stored on a local storage medium after being downloaded via a network. Thus, the methods described herein can be processed by software stored on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. The storage medium can be a magnetic disk, optical disk, read-only memory, random access memory, flash memory, hard disk, or solid-state drive, etc.; further, the storage medium may also include combinations of the above types of memory. It is understood that computers, processors, microprocessor controllers, or programmable hardware include storage components capable of storing or receiving software or computer code that, when accessed and executed by the computer, processor, or hardware, implements the table update method shown in the above embodiments.

[0132] A portion of this disclosure can be applied to computer program products, such as computer program instructions, which, when executed by a computer, can invoke or provide methods and / or technical solutions according to this disclosure through the operation of the computer. Those skilled in the art will understand that the forms in which computer program instructions exist in a computer-readable medium include, but are not limited to, source files, executable files, and installation package files. Accordingly, the ways in which computer program instructions are executed by a computer include, but are not limited to: the computer directly executing the instructions; the computer compiling the instructions and then executing the corresponding compiled program; the computer reading and executing the instructions; or the computer reading and installing the instructions and then executing the corresponding installed program. Here, the computer-readable medium can be any available computer-readable storage medium or communication medium accessible to a computer.

[0133] Although embodiments of the present disclosure have been described in conjunction with the accompanying drawings, those skilled in the art can make various modifications and variations without departing from the spirit and scope of the present disclosure, and such modifications and variations all fall within the scope defined by the appended claims.

Claims

1. A method for updating a data table, characterized in that, The method includes: Obtain the upstream raw data table and downstream consumption indicator table corresponding to the target business scenario. The upstream raw data table includes a first indicator with multiple variable dimensions, a second indicator with multiple immutable dimensions, and the indicator update time. Analyze each indicator in the downstream consumption indicator table to determine at least one target indicator of an immutable dimension; Based on the indicator update time in the upstream original data table, determine the indicator update amount of each target indicator at the target specified time. Obtain the previous time corresponding to the specified time of the target and the historical consumption index table corresponding to the previous time; The historical consumption indicator table is updated based on the indicator update amount to obtain the target data table corresponding to the specified target time.

2. The method according to claim 1, characterized in that, The step of analyzing each indicator in the downstream consumption indicator table to determine at least one target indicator with an immutable dimension includes: Analyze each indicator in the downstream consumption indicator table to determine the corresponding indicator data for each indicator. Based on the consumption status of the indicator data, at least one target indicator with an immutable dimension is extracted from each indicator in the downstream consumption indicator table.

3. The method according to claim 2, characterized in that, The step of extracting at least one target indicator with an immutable dimension from each indicator in the downstream consumption indicator table includes: Obtain multiple third indicators of immutable dimensions extracted from the downstream consumption indicator table; Based on the indicator dimension corresponding to the third indicator, multiple third indicators are aggregated to obtain at least one target indicator.

4. The method according to any one of claims 1-3, characterized in that, The step of determining the update amount of each target indicator at a specified target time based on the indicator update time in the upstream original data table includes: Based on the indicator update time in the upstream original data table, obtain the amount of data change in the upstream original data table at the target specified time. Based on the data change volume and the data consumption logic corresponding to the downstream consumption indicator table, the indicator update volume corresponding to each target indicator is determined.

5. The method according to claim 4, characterized in that, The step of determining the update amount of each target indicator based on the data change amount and the data consumption logic corresponding to the downstream consumption indicator table includes: Based on the correlation between the data change volume and each of the target indicators, obtain the associated change volume corresponding to each of the target indicators; Based on the data consumption logic corresponding to the downstream consumption indicator table, the indicator update volume generated by each target indicator under the associated change volume is obtained.

6. The method according to claim 4, characterized in that, The step of obtaining the data change amount of the upstream original data table at the target specified time based on the indicator update time in the upstream original data table includes: By comparing the update times of each indicator in the upstream original data table with the target specified time, the amount of target data whose indicator update time is the same as the target specified time is determined. The target data volume is defined as the data change volume.

7. The method according to claim 1, characterized in that, The step of updating the historical consumption indicator table based on the indicator update amount to obtain the target data table corresponding to the target specified time includes: Obtain the historical indicator quantity corresponding to each of the target indicators in the historical consumption indicator table; The historical indicator values ​​are updated using the indicator update amount to obtain the target data table at the specified target time.

8. The method according to claim 7, characterized in that, The step of updating the historical indicator values ​​using the indicator update amount to obtain the target data table at the specified target time includes: The historical indicator values ​​are deleted from the historical consumption indicator table to obtain the consumption indicator adjustment table. The updated index is merged with the consumption index adjustment table to generate the target data table.

9. A data table updating device, characterized in that, The device includes: The data acquisition module is used to acquire the upstream raw data table and the downstream consumption indicator table corresponding to the target business scenario. The upstream raw data table includes a first indicator with multiple variable dimensions, a second indicator with multiple immutable dimensions, and the indicator update time. The parsing module is used to parse the various indicators in the downstream consumption indicator table and determine multiple target indicators with immutable dimensions. The update quantity determination module is used to determine the update quantity of each target indicator at a specified target time based on the indicator update time in the upstream original data table. The historical data acquisition module is used to acquire the previous time corresponding to the specified time of the target and the historical consumption index table corresponding to the previous time. The data update module is used to update the historical consumption indicator table based on the indicator update amount to obtain the target data table corresponding to the target specified time.

10. An electronic device, characterized in that, include: A memory and a processor are communicatively connected, the memory storing computer instructions, and the processor executing the computer instructions to perform the data table update method of any one of claims 1 to 8.

11. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions for causing a computer to perform the method for updating a data table as described in any one of claims 1 to 8.

12. A computer program product, characterized in that, Includes computer instructions for causing a computer to perform the method for updating a data table as described in any one of claims 1 to 8.

Citation Information

Patent Citations

  • Data processing method, device and equipment

    CN110647563A

  • Data processing method, computer equipment and readable storage medium

    CN112131239A

  • Service data processing method and device and storage medium

    CN112364021A

  • Data processing method for spreadsheet, medium, electronic device and program product

    US20250298968A1