Business data management method and device for online spreadsheets
By using automatic fuzzy matching and business validation methods, the problems of low data storage efficiency and consistency in online spreadsheets have been solved, achieving efficient and accurate data management.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-01-13
- Publication Date
- 2026-04-03
AI Technical Summary
In online spreadsheets, users need to manually search and select database field tags for data storage, which is inefficient and error-prone. Furthermore, data consistency is difficult to guarantee in a multi-user environment, and errors caused by misoperation are difficult to correct quickly.
By automatically identifying the target cell and performing fuzzy matching, the database field markers corresponding to the target business data are identified and stored. Business validation is performed during undo operations to restore the original data.
It improved data entry efficiency, reduced human error, ensured the accuracy and consistency of data storage, and reduced operational risks.
Smart Images

Figure CN121501803B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of digital management technology, and in particular to a business data management method and apparatus for online spreadsheets. Background Technology
[0002] In the manufacturing sector, companies need to efficiently manage and maintain large amounts of production data, such as production orders, bills of materials (BOMs), and workshop work reports. Taking production order management as an example, planners need to batch enter product information (such as product codes, names, specifications, etc.) into the online system based on sales orders.
[0003] Currently, when users enter data into the system's online spreadsheet, they need to manually search and select the corresponding database field markers for data storage. This manual selection is inefficient and prone to errors. Furthermore, due to data consistency issues in a multi-user environment, once data entry is completed and saved, it cannot be undone, making it difficult to quickly correct data errors caused by user mistakes and increasing operational risks.
[0004] Therefore, how to implement batch copy-paste and undo operations for data in online spreadsheets is an urgent problem to be solved. Summary of the Invention
[0005] This application provides a business data management method and apparatus for online spreadsheets. To provide a basic understanding of some aspects of the disclosed embodiments, a brief summary is given below. This summary is not intended as a general description, nor is it intended to identify key / important components or describe the scope of protection of these embodiments. Its sole purpose is to present some concepts in a simple form as a prelude to the detailed description that follows.
[0006] In a first aspect, embodiments of this application provide a business data management method for online spreadsheets, the method comprising:
[0007] In response to user instructions regarding business data management in an online spreadsheet, determine the target cell in the online spreadsheet that the user is operating on;
[0008] Retrieve the target business data currently displayed in the target cell;
[0009] When a business data management command instructs a copy-and-paste operation, the target business data is fuzzily matched with existing historical business data in the database to determine the corresponding database field markers for data storage; or...
[0010] When the business data management command indicates that the operation should be undone, retrieve the original data in the target cell before the data change; perform business validation based on the original data to obtain the validation result; if the validation result indicates that the original data meets the data conditions and business logic conditions, update the target business data to the original data.
[0011] Optionally, the database field tags corresponding to the target business data are determined for data storage, including:
[0012] If the fuzzy search results show that each target business data has a database field marker, then populate and display the corresponding database field marker for each target business data in an online spreadsheet; or,
[0013] If the fuzzy search results show that each target business data has multiple database field tags, display multiple database field tags and prompt the user to manually select the database field tags; or,
[0014] If the fuzzy search results show that no database field tag exists for each target business data, display a matching failure message to prompt the user to manually enter the database field tag.
[0015] Receive the database field tags corresponding to each target business data determined by the user for the information to be displayed, and fill and display the database field tags corresponding to each target business data in an online spreadsheet;
[0016] The database stores the mapping relationship between each target business data and the corresponding database field tag.
[0017] Optionally, perform business validation based on the original data to obtain the validation results, including:
[0018] Based on the database field tags corresponding to the target business data, determine the business logic parameters that are related to the original data;
[0019] Based on the business logic parameters, determine whether the original data meets the data conditions and business logic conditions of the current actual business scenario;
[0020] If so, generate a verification result indicating that the original data meets the data conditions and business logic conditions;
[0021] If not, generate a verification result indicating that the original data does not meet the data conditions and business logic conditions.
[0022] Optionally, based on the database field tags corresponding to the target business data, determine the business logic parameters that are related to the original data, including:
[0023] From the pre-established mapping relationship between database field tags and business entities, obtain the target business entity corresponding to the database field tag of the target business data;
[0024] Load the predefined business relationship model, which is a directed node graph used to describe the association rules between different business entities in the system;
[0025] Starting with the target business entity, the system iterates through the predefined business relationship model, including the associated business entities related to the target business entity and the business rule attribute information between the target business entity and each of the associated business entities it traverses.
[0026] Retrieve the latest status information of each related business entity from the database;
[0027] The latest status information and business rule attribute information are used as business logic parameters that are related to the original data.
[0028] Optionally, the following steps are used to generate a pre-established mapping relationship between database field tags and business entities, and a predefined business relationship model, including:
[0029] Based on the database table design documents, obtain all business objects involved in the system;
[0030] Each business object is converted into a business entity, and the corresponding database field tag for each business entity is determined in the database.
[0031] Store the mapping relationship between each business entity and its corresponding database field tag in the database, and obtain the pre-established mapping relationship between database field tags and business entities;
[0032] For each business entity, a business relevance analysis is performed with other business entities to obtain relationship type attribute information and business rule attribute information between each business entity and other business entities; among which, the relationship type attribute information includes attribution relationship, dependency relationship, reference relationship, and parent-child relationship;
[0033] By associating each business entity with other business entities using the relationship type attribute information, a directed graph is obtained.
[0034] By using the business rule attribute information between each business entity and other business entities, association rules are marked on the connection edges between business entities in the directed graph, thus obtaining a predefined business relationship model.
[0035] Optionally, perform business relevance analysis on each business entity and other business entities to obtain relationship type attribute information and business rule attribute information between each business entity and other business entities, including:
[0036] Obtain the system's database ER diagram, business process diagram, and business specification documents;
[0037] Each business entity is the primary analysis object, and all other business entities besides the primary analysis object are secondary analysis objects.
[0038] Each auxiliary analysis object is associated with the main analysis object to obtain a relationship analysis matrix for each business entity.
[0039] By using the database ER diagram, check whether there are direct foreign key references in the relationship analysis matrix of each business entity, and record the direction of the association and the associated database fields as relationship type attribute information;
[0040] By examining business process diagrams and business specification documents, the constraints and validation conditions between entities in the relationship analysis matrix of each business entity are used as business rule attribute information.
[0041] Optionally, the business logic parameters include the latest status information of each associated business entity being traversed, and the business rule attribute information between the target business entity corresponding to the database field tag and each associated business entity being traversed.
[0042] Based on business logic parameters, determine whether the original data meets the data conditions and business logic conditions of the current actual business scenario, including:
[0043] Determine the data type, value range, and data uniqueness identifier of the database fields corresponding to the target business data;
[0044] Based on the data type, value range, and data uniqueness identifier, determine whether the original data meets the requirements of the data type, value range, and data uniqueness, and obtain the data judgment result;
[0045] By using the latest status information of each associated business entity, it is determined whether the status of each associated business entity meets the business requirements, and whether the metadata conforms to the business rule attribute information between the target business entity corresponding to the database field tag and each associated business entity traversed, thus obtaining the business logic judgment result;
[0046] If both the data judgment result and the business logic judgment result are yes, then the original data is determined to meet the data conditions and business logic conditions under the current actual business scenario.
[0047] Optionally, in response to a user's command to open an online spreadsheet, a data change log module is initialized for each cell in the online spreadsheet; the data change log module is used to store the data status of the cell at different operation stages;
[0048] In response to user commands to modify data in a target cell, monitor and capture data change events for the target cell. Data change events include the cell identifier information of the target cell, the historical timestamp of the change, the original data before the change, and the business data currently displayed after the change.
[0049] Encapsulate the cell identifier information of the target cell, the historical timestamp of the change, the original data before the change, and the business data currently displayed after the change into a four-tuple;
[0050] A module for storing data change records from quadruples to target cells.
[0051] Optionally, retrieve the original data in the target cell before the data change, including:
[0052] Obtain the cell identifier information of the target cell;
[0053] The module retrieves the data change history of the target cell; the data change history module is used to store the data status of the cell at different stages of operation.
[0054] From the multiple quadruples stored in the data change record module, which contain cell identifier information, historical timestamp, original data before the change, and business data after the change, find the target quadruple that is closest to the current time corresponding to the cell identifier information of the target cell.
[0055] Retrieve the original data before the change from the target quadruple and use it as the original data before the change in the target cell.
[0056] Secondly, embodiments of this application provide a business data management device for online spreadsheets, the device comprising:
[0057] The target cell determination module is used to determine the target cell in the online spreadsheet that the user is operating on in response to the user's business data management instructions for the online spreadsheet.
[0058] The business data acquisition module is used to acquire the target business data currently displayed in the target cell;
[0059] The data management module is used to perform a fuzzy match between the target business data and existing historical business data in the database when a copy-paste operation is instructed by a business data management command, in order to determine the database field markers corresponding to the target business data for data storage; or,
[0060] When the business data management command indicates that the operation should be undone, retrieve the original data in the target cell before the data change; perform business validation based on the original data to obtain the validation result; if the validation result indicates that the original data meets the data conditions and business logic conditions, update the target business data to the original data.
[0061] The technical solutions provided in this application embodiment may include the following beneficial effects:
[0062] In this embodiment, on the one hand, when a user issues a business data management command, the system can automatically determine the target cell and obtain the target business data. Then, in the case of a copy-paste operation, the system performs a fuzzy match between the target business data and existing historical business data in the database to determine the corresponding database field markers for data storage. This avoids the tedious process of manually searching and selecting field markers, greatly improving the efficiency of data entry and reducing errors caused by human operation, thus ensuring the accuracy of data storage. On the other hand, during the undo operation, the system performs business verification by obtaining the original data in the target cell before the data change and obtains the verification result. If the verification result indicates that the original data meets the data conditions and business logic conditions, the target business data will be updated to the original data. This allows users to quickly restore to the correct state through the undo function even if a mistake occurs during data operations in a multi-user environment, ensuring data consistency and integrity and effectively reducing operational risks.
[0063] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and do not limit this application. Attached Figure Description
[0064] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0065] Figure 1 This is a schematic diagram of a method flow for business data management of online spreadsheets provided in an embodiment of this application;
[0066] Figure 2 This is a schematic diagram of the UI interface of an online spreadsheet provided in an embodiment of this application;
[0067] Figure 3 This is a schematic diagram of a UI interface for a fuzzy matching result provided in an embodiment of this application;
[0068] Figure 4 This is a schematic diagram of a UI interface for a fuzzy matching result provided in an embodiment of this application;
[0069] Figure 5 This is a schematic block diagram illustrating the process of a copy-paste operation provided in an embodiment of this application;
[0070] Figure 6 This is a schematic diagram of a UI interface for a verification result provided in an embodiment of this application;
[0071] Figure 7 This is a schematic block diagram illustrating the process of a cancellation operation provided in an embodiment of this application;
[0072] Figure 8 This is a schematic flowchart illustrating the process of obtaining the original data in a cell before a change, as provided in an embodiment of this application.
[0073] Figure 9 This is a schematic diagram of the structure of a business data management device for online spreadsheets provided in an embodiment of this application;
[0074] Figure 10 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0075] The following description and accompanying drawings fully illustrate specific embodiments of this application to enable those skilled in the art to practice them.
[0076] It should be understood that the described embodiments are merely some, not all, of the embodiments in this application. All other embodiments obtained by those skilled in the art based on the embodiments in this application without inventive effort are within the scope of protection of this application.
[0077] In the following description, when referring to the accompanying drawings, the same numbers in different drawings denote the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.
[0078] In the description of this application, it should be understood that the terms "first," "second," etc., are used for descriptive purposes only and should not be construed as indicating or implying relative importance. Those skilled in the art can understand the specific meaning of the above terms in this application based on the specific circumstances. Furthermore, in the description of this application, unless otherwise stated, "multiple" refers to two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship.
[0079] Currently, planners need to enter product information in batches into the online system based on sales orders.
[0080] The applicant of this application recognized that when users enter data into the system's online spreadsheet, they need to manually search and select the corresponding database field tags for data storage. Manual selection is inefficient and prone to errors. Furthermore, due to data consistency issues in a multi-user environment, once data entry is completed and saved, it cannot be undone, making it difficult to quickly correct data errors caused by user mistakes and increasing operational risks.
[0081] To address the aforementioned issues, this application provides a business data management method and apparatus for online spreadsheets, resolving the problems existing in the related technologies. In this embodiment, on one hand, when a user issues a business data management command, the system automatically identifies the target cell and obtains the target business data. Then, in the case of a copy-paste operation, the system performs a fuzzy match between the target business data and existing historical business data in the database to determine the corresponding database field markers for data storage. This avoids the tedious process of manually searching and selecting field markers, greatly improving data entry efficiency and reducing errors caused by human operation, ensuring the accuracy of data storage. On the other hand, during the undo operation, the system performs business verification by obtaining the original data in the target cell before the data change, obtaining the verification result. If the verification result indicates that the original data meets the data conditions and business logic conditions, the target business data is updated to the original data. This allows users to quickly restore to the correct state even if a misoperation occurs during data operations in a multi-user environment, ensuring data consistency and integrity and effectively reducing operational risks. The following describes the process in detail using exemplary embodiments.
[0082] The following will be combined with the appendix Figure 1 -Appendix Figure 8 This application provides a detailed description of the business data management method for online spreadsheets provided in its embodiments. This method can be implemented using a computer program and can run on a business data management device for online spreadsheets based on the von Neumann architecture. The computer program can be integrated into an application or run as a standalone utility application.
[0083] Please see Figure 1 This document provides a flowchart illustrating a business data management method for online spreadsheets, as described in an embodiment of this application. Figure 1 As shown, the method in this application embodiment includes the following steps:
[0084] S101, in response to the user's business data management instruction for the online spreadsheet, determines the target cell in the online spreadsheet that the user is operating on;
[0085] Online spreadsheets are internet-based spreadsheet tools that users can access and manipulate through a browser or other clients; they can be understood as an online version of Excel. The purpose of online spreadsheets is to provide a platform that allows users to input, edit, store, and manage business data, such as... Figure 2 As shown. Business data management commands are user-issued commands used to manipulate data in a spreadsheet, such as copy, paste, and undo. Business data management commands can trigger the system to perform corresponding data processing operations on target cells. The target cell is a specific cell in the spreadsheet the user is currently working with; it is the concrete object of the data manipulation, and the system needs to identify and process the data in that cell.
[0086] In some embodiments of this application, users operate through an online spreadsheet interface (such as a webpage or client). For example, a user selects a cell and then clicks the "Copy" button in the toolbar. The system captures the user's operation command through the front-end interface and converts it into a specific business data management command. After receiving the user command, the system first parses the command content to determine the type of operation the user wants to perform (such as copy, paste, undo, etc.). The system obtains the position information of the currently selected cell through the user interface's event listening mechanism. For example, if the user selects the cell in row 3 and column 5, the system will record the coordinates of this cell (e.g., A5). The system marks the cell selected by the user as the target cell and records its relevant information, such as the cell's row and column coordinates, and the currently displayed data content.
[0087] In one possible implementation, the user logs into an online spreadsheet system, opens an inventory management spreadsheet, for example... Figure 2 As shown. Locate the row containing high-density polyethylene raw material 1, and then select the cell in the "Inventory Quantity" column. Update the inventory quantity in cell H2 from 150 to 200, and click the save button. The system captures the business data management instruction, parses the instruction content, and determines the type of operation to be performed. It obtains the position information of the selected cell through an event listener mechanism and records the coordinates of this cell. The system marks the cell as the target cell and records its relevant information (such as the cell's row and column coordinates, currently displayed data content, etc.).
[0088] S102, retrieve the target business data currently displayed in the target cell;
[0089] The target business data consists of business-related information displayed in the target cell, such as product name, inventory quantity, and price. This target business data forms the basis for business operations and management and needs to be identified, processed, and stored by the system.
[0090] In some embodiments of this application, a user selects a cell in the spreadsheet interface by clicking or using a keyboard shortcut. The system captures the user's selection operation through an event listener mechanism in the front-end interface and identifies the selected cell. Based on the identified cell location, the system extracts the data from the spreadsheet's data model.
[0091] In one possible implementation, the user opens an inventory management table, for example... Figure 2 As shown. The user locates the row containing the high-density polyethylene raw material in the table and then clicks on the cell in the "Inventory Quantity" column. The system recognizes the selected cell and extracts the data displayed in the cell from the spreadsheet's data model; the inventory quantity is shown as 397.
[0092] S103, when the business data management instruction indicates a copy and paste operation, perform a fuzzy match between the target business data and the existing historical business data in the database to determine the database field marker corresponding to the target business data for data storage;
[0093] The copy-paste operation allows users to copy relevant data from a local file and paste it into a spreadsheet. Fuzzy matching is a data matching method that allows finding similar data even when they are not completely identical.
[0094] In some embodiments of this application, a user selects business data and copies it to a specified cell in a spreadsheet. The system retrieves the copied data from the spreadsheet. The system performs a fuzzy match between the target business data and historical business data in the database. Based on the matching result, the system determines the database field marker corresponding to the target business data. The system stores the target business data in the corresponding field marker location in the database.
[0095] It should be noted that fuzzy matching may result in three situations: a unique match, multiple matches, or no match at all.
[0096] In some embodiments of this application, the specific process of determining the database field markers corresponding to the target business data for data storage includes: when the fuzzy search results show that each target business data has one database field marker, filling and displaying the database field markers corresponding to each target business data in an online spreadsheet; or, when the fuzzy search results show that each target business data has multiple database field markers, displaying multiple database field markers and prompting the user to manually select a database field marker; or, when the fuzzy search results show that each target business data does not have a database field marker, displaying a matching failure message prompting the user to manually input a database field marker; receiving the database field markers corresponding to each target business data determined by the user based on the displayed information, and filling and displaying the database field markers corresponding to each target business data in an online spreadsheet; and storing the mapping relationship between each target business data and the database field markers corresponding to each target business data in the database.
[0097] For example, when a user copies "high-density polyethylene raw material" into a spreadsheet, the system performs a fuzzy match. If a unique result is found, the system populates and displays the database field markers corresponding to each target business data point in the online spreadsheet. If the user copies "polypropylene resin" into the spreadsheet, the system performs a fuzzy match but fails to find a unique result. In this case, the system displays a matching failure message prompting the user to manually enter the database field markers. Figure 3 As shown. After the user copies "HDPE-5000S" into the spreadsheet, the system performs a fuzzy match. If multiple results are found, the system displays multiple database field markers and prompts the user to manually select the database field markers, for example... Figure 4 As shown.
[0098] For example Figure 5 As shown, Figure 5This is a flowchart illustrating the copy-paste operation process provided in this application, where a user performs a copy-paste operation in a spreadsheet. The system identifies the target cell from which the user pastes data. The system extracts the currently displayed business data from the target cell. The system performs a fuzzy match between the extracted business data and historical business data in the database to find possible corresponding database field markers. Based on the fuzzy match results, the system proceeds to different processing branches. If the matching results show that each target business data has a specific database field marker, the system directly displays that field marker. The system displays the corresponding database field marker in the spreadsheet. The displayed field marker is updated in the target cell of the spreadsheet. If the matching results show that each target business data has multiple possible database field markers, the system prompts the user to select one manually. The system displays all possible field markers and prompts the user to select the correct one. The user selects a field marker from the prompts. If the matching results show that each target business data does not have any database field markers, the system prompts the user to enter one manually. The system prompts the user to enter a database field marker. The user manually enters a database field marker. Regardless of whether the user directly sees the field marker, selects the field marker, or enters the field marker, the system will store the mapping relationship between the target business data and the selected database field marker in the database.
[0099] In this embodiment of the application, or, when the business data management instruction indicates an undo operation, the original data in the target cell before the data change is obtained; business verification is performed based on the original data to obtain the verification result; if the verification result indicates that the original data meets the data conditions and business logic conditions, the target business data is updated to the original data.
[0100] The undo operation is an action performed by the user in the spreadsheet to undo previous changes or actions. The original data is the business data in the target cell before the change. The target business data is the data currently displayed in the target cell after the change.
[0101] In some embodiments of this application, the specific process of obtaining the original data of the target cell before the data change includes: obtaining the cell identifier information of the target cell; obtaining the data change record module of the target cell; the data change record module is used to store the data status of the cell at different operation stages; from the multiple quadruples stored in the data change record module, which include cell identifier information, historical timestamp, original data before the change, and business data after the change, searching for the target quadruple corresponding to the cell identifier information of the target cell that is closest to the current time; obtaining the original data before the change from the target quadruple, as the original data of the target cell before the data change.
[0102] Specifically, the data change log module stores data as follows: In response to a user's command to open an online spreadsheet, a data change log module is initialized for each cell in the online spreadsheet; the data change log module stores the data status of the cell at different operation stages; in response to a user's command to modify the data of a target cell, the module monitors and captures the data change event of the target cell, which includes the cell identifier information of the target cell, the historical timestamp of the change, the original data before the change, and the currently displayed business data after the change; the cell identifier information of the target cell, the historical timestamp of the change, the original data before the change, and the currently displayed business data after the change are encapsulated into a four-tuple;
[0103] A module for storing data change records from quadruples to target cells.
[0104] In some embodiments of this application, a user selects a target cell in a spreadsheet and performs an undo operation. The system retrieves the original data of the target cell before the change from the data change record. The system performs business validation based on the original data to check whether the data conditions and business logic conditions are met. The system obtains the result of the business validation. If the validation result shows that the original data meets the conditions, the system updates the target business data to the original data.
[0105] In one possible implementation, the user changes "ABS engineering plastic" to "ABS engineering plastic 1". The user then selects the target cell and clicks "Undo". The system will then perform a validation, and the validation result will be as follows: Figure 6 As shown, after the verification is successful, you can revert to "ABS Engineering Plastics".
[0106] In some embodiments of this application, the specific process of performing business verification based on the original data to obtain the verification result includes: determining the business logic parameters that are related to the original data based on the database field tags corresponding to the target business data; determining whether the original data meets the data conditions and business logic conditions under the current actual business scenario based on the business logic parameters; if yes, generating a verification result indicating that the original data meets the data conditions and business logic conditions; if no, generating a verification result indicating that the original data does not meet the data conditions and business logic conditions.
[0107] Specifically, the process of determining the business logic parameters related to the original data based on the database field tags corresponding to the target business data includes: obtaining the target business entity corresponding to the database field tags of the target business data from the pre-established mapping relationship between database field tags and business entities; loading a predefined business relationship model, which is a directed node graph used to describe the association rules between different business entities in the system; starting from the target business entity, traversing the associated business entities related to the target business entity from the predefined business relationship model, and the business rule attribute information between the target business entity and each traversed associated business entity; obtaining the latest status information of each associated business entity from the database; and using the latest status information and business rule attribute information as the business logic parameters related to the original data.
[0108] The business logic parameters include the latest status information of each associated business entity being traversed, and the business rule attribute information between the target business entity corresponding to the database field marker and each associated business entity being traversed.
[0109] Specifically, the process of generating the pre-established mapping relationship between database field tags and business entities, and the predefined business relationship model, includes: obtaining all business objects involved in the system based on the database table design file; converting each business object into a business entity and determining the corresponding database field tag for each business entity in the database; storing the mapping relationship between each business entity and its corresponding database field tag in the database, thus obtaining the pre-established mapping relationship between database field tags and business entities; performing business relevance analysis on each business entity and other business entities to obtain the relationship type attribute information and business rule attribute information between each business entity and other business entities; among which, the relationship type attribute information includes attribution relationship, dependency relationship, reference relationship, and parent-child relationship; associating each business entity with other business entities through the relationship type attribute information, thus obtaining a directed graph; and annotating the association rules on the connection edges between business entities in the directed graph through the business rule attribute information between each business entity and other business entities, thus obtaining the predefined business relationship model.
[0110] Specifically, the process of performing business relevance analysis on each business entity and other business entities to obtain relationship type attribute information and business rule attribute information for each business entity and other business entities includes: obtaining the system's database ER diagram, business process diagram, and business specification document; using each business entity as the main analysis object and all other business entities besides the main analysis object as auxiliary analysis objects; associating each auxiliary analysis object with the main analysis object to obtain the relationship analysis matrix for each business entity; checking whether there are direct foreign key references in the relationship analysis matrix of each business entity through the database ER diagram, and recording the direction of association and the associated database fields as relationship type attribute information; and checking the constraints and validation conditions between entities in the relationship analysis matrix of each business entity through the business process diagram and business specification document as business rule attribute information.
[0111] In some embodiments of this application, the specific process of determining whether the original data meets the data conditions and business logic conditions under the current actual business scenario based on business logic parameters includes: determining the data type, value range, and data uniqueness identifier of the database field marker corresponding to the target business data; determining whether the original data meets the requirements of the data type, value range, and data uniqueness based on the data type, value range, and data uniqueness identifier, and obtaining a data judgment result; determining whether the status of each associated business entity meets the business requirements through the latest status information of each associated business entity, and determining whether the metadata meets the business rule attribute information between the target business entity corresponding to the database field marker and each traversed associated business entity, and obtaining a business logic judgment result; if both the data judgment result and the business logic judgment result are yes, determining that the original data meets the data conditions and business logic conditions under the current actual business scenario.
[0112] For example Figure 7 As shown, Figure 7This is a flowchart illustrating the process of an undo operation provided in this application. A user performs an undo operation in a spreadsheet, intending to cancel recent changes. The system identifies and determines the target cell from which the user wants to undo the changes. The system retrieves the original data of the target cell before the change from the data change record. The original data is used to perform a series of business rule checks to ensure data accuracy and compliance. Based on the mapping relationship between business data and the database, the system determines the database field tags corresponding to the original data. A predefined business relationship model is loaded, which describes the association rules between different business entities in the system. Starting from the target business entity, all associated business entities are traversed. The latest status information of all associated business entities is retrieved from the database. Business rule attribute information related to the business entities is retrieved; this information is used for subsequent verification. The system checks whether the original data meets data conditions such as data type, value range, and data uniqueness. The system checks whether the original data meets business logic conditions, such as the status of associated business entities and business rules. If the original data meets all data and business logic conditions, the update operation continues. The business data in the target cell is updated to the verified original data. If the original data does not meet the conditions, the update operation is not performed. If the validation fails, keep the current data in the target cell unchanged.
[0113] For example Figure 8 As shown, Figure 8 This application provides a schematic flowchart illustrating the process of retrieving the original data before a change in a cell. The user opens a spreadsheet. The system automatically initializes a data change record module for each cell in the spreadsheet. When the user modifies data in a cell, the system monitors and captures the data change event of the target cell. The system encapsulates the cell identifier information, the historical timestamp of the change, the original data before the change, and the currently displayed business data after the change into a four-tuple. This four-tuple is stored in the target cell's data change record module. After the user triggers an undo operation, the system retrieves the target cell's identifier information. It then retrieves the target cell's data change record module. The system searches for the target four-tuple closest to the current time within the data change record module. Finally, it retrieves the original data before the change from the found four-tuple.
[0114] In this embodiment, on the one hand, when a user issues a business data management command, the system can automatically determine the target cell and obtain the target business data. Then, in the case of a copy-paste operation, the system performs a fuzzy match between the target business data and existing historical business data in the database to determine the corresponding database field markers for data storage. This avoids the tedious process of manually searching and selecting field markers, greatly improving the efficiency of data entry and reducing errors caused by human operation, thus ensuring the accuracy of data storage. On the other hand, during the undo operation, the system performs business verification by obtaining the original data in the target cell before the data change and obtains the verification result. If the verification result indicates that the original data meets the data conditions and business logic conditions, the target business data will be updated to the original data. This allows users to quickly restore to the correct state through the undo function even if a mistake occurs during data operations in a multi-user environment, ensuring data consistency and integrity and effectively reducing operational risks.
[0115] The following are embodiments of the apparatus described in this application, which can be used to execute the embodiments of the method described in this application. For details not disclosed in the apparatus embodiments of this application, please refer to the embodiments of the method described in this application.
[0116] Please see Figure 9 This illustration shows a schematic diagram of a business data management device for online spreadsheets provided in an exemplary embodiment of this application. This business data management device for online spreadsheets can be implemented as all or part of an electronic device through software, hardware, or a combination of both. The device 1 includes a target cell determination module 10, a business data acquisition module 20, and a data management module 30.
[0117] The target cell determination module 10 is used to determine the target cell in the online spreadsheet that the user is operating on in response to the user's business data management instructions for the online spreadsheet.
[0118] Business data acquisition module 20 is used to acquire the target business data currently displayed in the target cell;
[0119] Data management module 30 is used to perform a fuzzy match between the target business data and existing historical business data in the database when a copy-paste operation is instructed by a business data management command, in order to determine the database field markers corresponding to the target business data for data storage; or,
[0120] When the business data management command indicates that the operation should be undone, retrieve the original data in the target cell before the data change; perform business validation based on the original data to obtain the validation result; if the validation result indicates that the original data meets the data conditions and business logic conditions, update the target business data to the original data.
[0121] It should be noted that the above embodiments of the business data management device for online spreadsheets, when executing the business data management method for online spreadsheets, only illustrate the division of the above functional modules. In practical applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. Furthermore, the business data management device for online spreadsheets and the embodiments of the business data management method for online spreadsheets belong to the same concept, and their implementation process is detailed in the method embodiments, which will not be repeated here.
[0122] The sequence numbers of the embodiments in this application are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.
[0123] In this embodiment, on the one hand, when a user issues a business data management command, the system can automatically determine the target cell and obtain the target business data. Then, in the case of a copy-paste operation, the system performs a fuzzy match between the target business data and existing historical business data in the database to determine the corresponding database field markers for data storage. This avoids the tedious process of manually searching and selecting field markers, greatly improving the efficiency of data entry and reducing errors caused by human operation, thus ensuring the accuracy of data storage. On the other hand, during the undo operation, the system performs business verification by obtaining the original data in the target cell before the data change and obtains the verification result. If the verification result indicates that the original data meets the data conditions and business logic conditions, the target business data will be updated to the original data. This allows users to quickly restore to the correct state through the undo function even if a mistake occurs during data operations in a multi-user environment, ensuring data consistency and integrity and effectively reducing operational risks.
[0124] This application also provides a computer-readable medium having program instructions stored thereon, which, when executed by a processor, implement the business data management method for online spreadsheets provided in the above-described method embodiments.
[0125] This application also provides a computer program product containing instructions that, when run on a computer, cause the computer to execute the business data management method for online spreadsheets described in the various method embodiments above.
[0126] Please see Figure 10 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 10 As shown, the electronic device 1000 may include: at least one processor 1001, at least one network interface 1004, a user interface 1003, a memory 1005, and at least one communication bus 1002.
[0127] The communication bus 1002 is used to realize the connection and communication between these components.
[0128] The user interface 1003 may include a display screen and a camera. Optionally, the user interface 1003 may also include a standard wired interface and a wireless interface.
[0129] The network interface 1004 may optionally include a standard wired interface or a wireless interface (such as a Wi-Fi interface).
[0130] The processor 1001 may include one or more processing cores. The processor 1001 connects to various parts within the electronic device 1000 using various interfaces and lines. It executes various functions and processes data by running or executing instructions, programs, code sets, or instruction sets stored in the memory 1005, and by calling data stored in the memory 1005. Optionally, the processor 1001 may be implemented using at least one hardware form selected from Digital Signal Processing (DSP), Field-Programmable Gate Array (FPGA), and Programmable Logic Array (PLA). The processor 1001 may integrate one or more of the following: a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), and a modem. The CPU primarily handles the operating system, user interface, and applications; the GPU is responsible for rendering and drawing the content to be displayed on the screen; and the modem handles wireless communication. It is understood that the modem may also be implemented as a separate chip, without being integrated into the processor 1001.
[0131] The memory 1005 may include random access memory (RAM) or read-only memory. Optionally, the memory 1005 may include a non-transitory computer-readable storage medium. The memory 1005 can be used to store instructions, programs, code, code sets, or instruction sets. The memory 1005 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as touch function, sound playback function, image playback function, etc.), instructions for implementing the above-described method embodiments, etc.; the data storage area may store data involved in the above-described method embodiments, etc. Optionally, the memory 1005 may also be at least one storage system located remotely from the aforementioned processor 1001. Figure 10 As shown, the memory 1005, which serves as a computer storage medium, may include an operating system, a network communication module, a user interface module, and a business data management application for online spreadsheets.
[0132] exist Figure 10 In the illustrated electronic device 1000, the user interface 1003 is mainly used to provide an input interface for the user and to obtain the user's input data; while the processor 1001 can be used to call the business data management application for online spreadsheets stored in the memory 1005, and specifically perform the following operations:
[0133] In response to user instructions regarding business data management in an online spreadsheet, determine the target cell in the online spreadsheet that the user is operating on;
[0134] Retrieve the target business data currently displayed in the target cell;
[0135] When a business data management command instructs a copy-and-paste operation, the target business data is fuzzily matched with existing historical business data in the database to determine the corresponding database field markers for data storage; or...
[0136] When the business data management command indicates that the operation should be undone, retrieve the original data in the target cell before the data change; perform business validation based on the original data to obtain the validation result; if the validation result indicates that the original data meets the data conditions and business logic conditions, update the target business data to the original data.
[0137] In one embodiment, when the processor 1001 performs data storage by determining the database field marker corresponding to the target business data, it specifically performs the following operations:
[0138] If the fuzzy search results show that each target business data has a database field marker, then populate and display the corresponding database field marker for each target business data in an online spreadsheet; or,
[0139] If the fuzzy search results show that each target business data has multiple database field tags, display multiple database field tags and prompt the user to manually select the database field tags; or,
[0140] If the fuzzy search results show that no database field tag exists for each target business data, display a matching failure message to prompt the user to manually enter the database field tag.
[0141] Receive the database field tags corresponding to each target business data determined by the user for the information to be displayed, and fill and display the database field tags corresponding to each target business data in an online spreadsheet;
[0142] The database stores the mapping relationship between each target business data and the corresponding database field tag.
[0143] In one embodiment, when the processor 1001 performs business verification based on the original data and obtains the verification result, it specifically performs the following operations:
[0144] Based on the database field tags corresponding to the target business data, determine the business logic parameters that are related to the original data;
[0145] Based on the business logic parameters, determine whether the original data meets the data conditions and business logic conditions of the current actual business scenario;
[0146] If so, generate a verification result indicating that the original data meets the data conditions and business logic conditions;
[0147] If not, generate a verification result indicating that the original data does not meet the data conditions and business logic conditions.
[0148] In one embodiment, when processor 1001 executes business logic parameters that are related to the original data based on the database field tags corresponding to the target business data, it specifically performs the following operations:
[0149] From the pre-established mapping relationship between database field tags and business entities, obtain the target business entity corresponding to the database field tag of the target business data;
[0150] Load the predefined business relationship model, which is a directed node graph used to describe the association rules between different business entities in the system;
[0151] Starting with the target business entity, the system iterates through the predefined business relationship model, including the associated business entities related to the target business entity and the business rule attribute information between the target business entity and each of the associated business entities it traverses.
[0152] Retrieve the latest status information of each related business entity from the database;
[0153] The latest status information and business rule attribute information are used as business logic parameters that are related to the original data.
[0154] In one embodiment, when the processor 1001 generates a pre-established mapping relationship between database field tags and business entities, and a predefined business relationship model, it specifically performs the following operations:
[0155] Based on the database table design documents, obtain all business objects involved in the system;
[0156] Each business object is converted into a business entity, and the corresponding database field tag for each business entity is determined in the database.
[0157] Store the mapping relationship between each business entity and its corresponding database field tag in the database, and obtain the pre-established mapping relationship between database field tags and business entities;
[0158] For each business entity, a business relevance analysis is performed with other business entities to obtain relationship type attribute information and business rule attribute information between each business entity and other business entities; among which, the relationship type attribute information includes attribution relationship, dependency relationship, reference relationship, and parent-child relationship;
[0159] By associating each business entity with other business entities using the relationship type attribute information, a directed graph is obtained.
[0160] By using the business rule attribute information between each business entity and other business entities, association rules are marked on the connection edges between business entities in the directed graph, thus obtaining a predefined business relationship model.
[0161] In one embodiment, when the processor 1001 performs a business relevance analysis on each business entity and other business entities to obtain relationship type attribute information and business rule attribute information between each business entity and other business entities, it specifically performs the following operations:
[0162] Obtain the system's database ER diagram, business process diagram, and business specification documents;
[0163] Each business entity is the primary analysis object, and all other business entities besides the primary analysis object are secondary analysis objects.
[0164] Each auxiliary analysis object is associated with the main analysis object to obtain a relationship analysis matrix for each business entity.
[0165] By using the database ER diagram, check whether there are direct foreign key references in the relationship analysis matrix of each business entity, and record the direction of the association and the associated database fields as relationship type attribute information;
[0166] By examining business process diagrams and business specification documents, the constraints and validation conditions between entities in the relationship analysis matrix of each business entity are used as business rule attribute information.
[0167] In one embodiment, when the processor 1001 performs the operation of determining whether the original data meets the data conditions and business logic conditions under the current actual business scenario based on business logic parameters, it specifically performs the following operations:
[0168] Determine the data type, value range, and data uniqueness identifier of the database fields corresponding to the target business data;
[0169] Based on the data type, value range, and data uniqueness identifier, determine whether the original data meets the requirements of the data type, value range, and data uniqueness, and obtain the data judgment result;
[0170] By using the latest status information of each associated business entity, it is determined whether the status of each associated business entity meets the business requirements, and whether the metadata conforms to the business rule attribute information between the target business entity corresponding to the database field tag and each associated business entity traversed, thus obtaining the business logic judgment result;
[0171] If both the data judgment result and the business logic judgment result are yes, then the original data is determined to meet the data conditions and business logic conditions under the current actual business scenario.
[0172] In one embodiment, the processor 1001 also performs the following operations:
[0173] In response to a user's command to open an online spreadsheet, a data change record module is initialized for each cell in the online spreadsheet; the data change record module is used to store the data status of the cell at different operation stages;
[0174] In response to user commands to modify data in a target cell, monitor and capture data change events for the target cell. Data change events include the cell identifier information of the target cell, the historical timestamp of the change, the original data before the change, and the business data currently displayed after the change.
[0175] Encapsulate the cell identifier information of the target cell, the historical timestamp of the change, the original data before the change, and the business data currently displayed after the change into a four-tuple;
[0176] A module for storing data change records from quadruples to target cells.
[0177] In one embodiment, when the processor 1001 retrieves the original data in the target cell before the data change, it specifically performs the following operations:
[0178] Obtain the cell identifier information of the target cell;
[0179] The module retrieves the data change history of the target cell; the data change history module is used to store the data status of the cell at different stages of operation.
[0180] From the multiple quadruples stored in the data change record module, which contain cell identifier information, historical timestamp, original data before the change, and business data after the change, find the target quadruple that is closest to the current time corresponding to the cell identifier information of the target cell.
[0181] Retrieve the original data before the change from the target quadruple and use it as the original data before the change in the target cell.
[0182] In this embodiment, on the one hand, when a user issues a business data management command, the system can automatically determine the target cell and obtain the target business data. Then, in the case of a copy-paste operation, the system performs a fuzzy match between the target business data and existing historical business data in the database to determine the corresponding database field markers for data storage. This avoids the tedious process of manually searching and selecting field markers, greatly improving the efficiency of data entry and reducing errors caused by human operation, thus ensuring the accuracy of data storage. On the other hand, during the undo operation, the system performs business verification by obtaining the original data in the target cell before the data change and obtains the verification result. If the verification result indicates that the original data meets the data conditions and business logic conditions, the target business data will be updated to the original data. This allows users to quickly restore to the correct state through the undo function even if a mistake occurs during data operations in a multi-user environment, ensuring data consistency and integrity and effectively reducing operational risks.
[0183] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The program for managing business data in online spreadsheets can be stored in a computer-readable storage medium. When executed, the program can include the processes of the embodiments of the above methods. The storage medium for the program for managing business data in online spreadsheets can be a magnetic disk, optical disk, read-only memory, or random access memory, etc.
[0184] The above-disclosed embodiments are merely preferred embodiments of this application and should not be construed as limiting the scope of this application. Therefore, any equivalent variations made in accordance with the claims of this application shall still fall within the scope of this application.
Claims
1. A business data management method for online spreadsheets, characterized in that, The method includes: In response to a user's instruction on business data management in an online spreadsheet, the target cell in the online spreadsheet that the user is operating on is determined; Retrieve the target business data currently displayed in the target cell; When the business data management instruction indicates a copy and paste operation, the target business data is fuzzily matched with existing historical business data in the database to determine the database field marker corresponding to the target business data for data storage; When the business data management instruction indicates an undo operation, the original data in the target cell before the data change is obtained; business verification is performed based on the original data to obtain the verification result; when the verification result indicates that the original data meets the data conditions and business logic conditions, the target business data is updated to the original data. The step of performing business verification based on the original data to obtain the verification result includes: Based on the database field tags corresponding to the target business data, determine the business logic parameters that are related to the original data; based on the business logic parameters, determine whether the original data meets the data conditions and business logic conditions under the current actual business scenario; if yes, generate a verification result indicating that the original data meets the data conditions and business logic conditions; if no, generate a verification result indicating that the original data does not meet the data conditions and business logic conditions. The step of determining the business logic parameters that are related to the original data based on the database field tags corresponding to the target business data includes: From the pre-established mapping relationship between database field tags and business entities, obtain the target business entity corresponding to the database field tag of the target business data; load a predefined business relationship model, which is a directed node graph used to describe the association rules between different business entities in the system; starting from the target business entity, traverse the associated business entities that are associated with the target business entity and the business rule attribute information between the target business entity and each traversed associated business entity from the predefined business relationship model; obtain the latest status information of each associated business entity from the database; and use the latest status information and the business rule attribute information as business logic parameters that are related to the original data.
2. The method according to claim 1, characterized in that, The step of determining the database field markers corresponding to the target business data for data storage includes: If the fuzzy search results show that each target business data has a database field marker, then populate and display the database field marker corresponding to each target business data in an online spreadsheet; or, If the fuzzy search results show that each target business data item has multiple database field tags, display multiple database field tags and prompt the user to manually select a database field tag; or, If the fuzzy search results show that each target business data does not have a database field marker, a matching failure message is displayed to prompt the user to manually enter the database field marker. Receive the database field markers corresponding to each target business data as determined by the user for the information to be displayed, and fill and display the database field markers corresponding to each target business data in an online spreadsheet; The database stores the mapping relationship between each target business data and the corresponding database field tag.
3. The method according to claim 1, characterized in that, The following steps are used to generate the pre-established mapping relationship between database field tags and business entities, and the predefined business relationship model: Based on the design files of the data tables in the database, obtain all business objects involved in the system; Each business object is converted into a business entity, and the corresponding database field tag for each business entity is determined in the database. Store the mapping relationship between each business entity and the corresponding database field tag in the database, and obtain the pre-established mapping relationship between database field tags and business entities; For each business entity, a business relevance analysis is performed with other business entities to obtain relationship type attribute information and business rule attribute information between each business entity and other business entities; wherein, the relationship type attribute information includes attribution relationship, dependency relationship, reference relationship, and parent-child relationship; By using the relationship type attribute information between each business entity and other business entities, each business entity is associated with other business entities to obtain a directed graph; By using the business rule attribute information between each business entity and other business entities, association rules are marked on the connection edges between business entities in the directed graph to obtain a predefined business relationship model.
4. The method according to claim 3, characterized in that, The process of performing business relevance analysis on each business entity and other business entities yields relationship type attribute information and business rule attribute information between each business entity and other business entities, including: Obtain the system's database ER diagram, business process diagram, and business specification documents; Each business entity is the primary analysis object, and all other business entities besides the primary analysis object are secondary analysis objects. Each auxiliary analysis object is associated with the main analysis object to obtain a relationship analysis matrix for each business entity. By using the database ER diagram, check whether there is a direct foreign key reference relationship in the relationship analysis matrix of each business entity, and record the direction of association and the associated database fields as relationship type attribute information; By examining the business process diagram and business specification document, the constraints and verification conditions between entities in each business entity relationship analysis matrix are used as business rule attribute information.
5. The method according to claim 1, characterized in that, The business logic parameters include the latest status information of each associated business entity traversed, and the business rule attribute information between the target business entity corresponding to the database field marker and each associated business entity traversed. The step of determining whether the original data meets the data conditions and business logic conditions under the current actual business scenario based on the business logic parameters includes: Determine the data type, value range, and data uniqueness identifier of the database field markers corresponding to the target business data; Based on the data type, value range, and data uniqueness identifier, determine whether the original data meets the requirements of the data type, value range, and data uniqueness, and obtain the data judgment result; Based on the latest status information of each associated business entity, it is determined whether the status of each associated business entity meets the business requirements, and whether the original data conforms to the business rule attribute information between the target business entity corresponding to the database field mark and each associated business entity traversed, so as to obtain the business logic judgment result. If both the data judgment result and the business logic judgment result are yes, it is determined that the original data meets the data conditions and business logic conditions under the current actual business scenario.
6. The method according to claim 1, characterized in that, The method further includes: In response to a user's command to open the online spreadsheet, a data change record module is initialized for each cell of the online spreadsheet; the data change record module is used to store the data status of the cell at different operation stages; In response to the user's instruction to modify the data of the target cell, the system monitors and captures the data change event of the target cell. The data change event includes the cell identifier information of the target cell, the historical timestamp of the change, the original data before the change, and the business data currently displayed after the change. The cell identifier information of the target cell, the historical timestamp of the change, the original data before the change, and the currently displayed business data after the change are encapsulated into a quadruple; A module for storing data change records from the quadruple to the target cell.
7. The method according to claim 1, characterized in that, The step of obtaining the original data in the target cell before the data change includes: Obtain the cell identifier information of the target cell; The module for obtaining the data change record of the target cell; the data change record module is used to store the data status of the cell at different operation stages; From the multiple quadruples stored in the data change record module, which contain cell identifier information, historical timestamp, original data before the change, and business data after the change, find the target quadruple that is closest to the current time corresponding to the cell identifier information of the target cell; Obtain the original data before the change from the target quadruple and use it as the original data before the data change in the target cell.
8. A business data management device for online spreadsheets implemented using the method described in any one of claims 1-7, characterized in that, The device includes: The target cell determination module is used to determine the target cell in the online spreadsheet that the user is operating on in response to the user's business data management instruction for the online spreadsheet. The business data acquisition module is used to acquire the target business data currently displayed in the target cell; The data management module is used to perform a fuzzy match between the target business data and existing historical business data in the database when the business data management instruction indicates a copy and paste operation, so as to determine the database field marker corresponding to the target business data for data storage; When the business data management instruction indicates an undo operation, the original data in the target cell before the data change is obtained; business verification is performed based on the original data to obtain the verification result; when the verification result indicates that the original data meets the data conditions and business logic conditions, the target business data is updated to the original data.
Citation Information
Patent Citations
Discontinuous region data batch copying method and system
CN114036915A
Data processing method and device, computer equipment and storage medium
CN117592947A