Formula editing processing method, formula grammar calculation method and related device
By calculating formula syntax on the server side, the formula editor and formula syntax module are decoupled, which solves the problem of browser lag in the formula editor and improves the user experience and ease of use when editing formulas.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BEIJING ZITIAO NETWORK TECH CO LTD
- Filing Date
- 2023-02-14
- Publication Date
- 2026-06-19
Smart Images

Figure CN116205201B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer data processing technology, and in particular to a formula editing and processing method, apparatus, electronic device and storage medium. Background Technology
[0002] To improve the user experience of formula editing and the ease of use of formula editors, formula syntax-related functions are often added to the formula editor.
[0003] The implementation of these functions is directly coupled with the database table where the formula editor is located, and the complex calculations of the formula syntax can cause the browser where the formula editor is located to lag. Summary of the Invention
[0004] In view of this, the purpose of this application is to propose a formula editing and processing method, a formula syntax calculation method, and related equipment to solve or partially solve the above-mentioned technical problems.
[0005] To achieve the above objectives, the first aspect of this application provides a formula editing method, comprising:
[0006] The system receives input formula parameter information in the formula editing area of the database table and generates formula syntax calculation instructions corresponding to the formula parameter information.
[0007] Send the formula syntax calculation instruction to the server so that the server performs formula syntax calculation according to the initial formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information;
[0008] Receive at least one formula syntax sent by the server and display the formula syntax.
[0009] Based on the same inventive concept, a second aspect of this application provides a formula syntax calculation method, including:
[0010] Receive formula and syntax calculation instructions sent by the client;
[0011] Perform formula syntax calculation according to the formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information, and send the at least one formula syntax to the client.
[0012] Based on the same inventive concept, a third aspect of this application provides a formula editing and processing apparatus, comprising:
[0013] The instruction generation module is configured to receive input formula parameter information in the formula editing area of the database table and generate formula syntax calculation instructions corresponding to the formula parameter information.
[0014] The instruction sending module is configured to send the formula syntax calculation instruction to the server so that the server performs formula syntax calculation according to the initial formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information.
[0015] The display module is configured to receive at least one formula syntax sent by the server and display the formula syntax.
[0016] Based on the same inventive concept, a fourth aspect of this application provides a formula syntax calculation device, comprising:
[0017] The instruction receiving module is configured to receive formula and syntax calculation instructions sent by the client;
[0018] The formula syntax calculation module is configured to perform formula syntax calculation according to the formula syntax calculation instruction, obtain at least one formula syntax corresponding to the formula parameter information, and send the at least one formula syntax to the client.
[0019] Based on the same inventive concept, the fifth aspect of this application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the method described in the first aspect or the second aspect.
[0020] Based on the same inventive concept, a sixth aspect of this application provides a non-transitory computer-readable storage medium storing computer instructions for causing a computer to perform the method described in the first or second aspect.
[0021] As described above, the formula editing method, formula syntax calculation method, and related equipment provided in this application receive input formula parameter information in the formula editing area of a database table, generate formula syntax calculation instructions corresponding to the formula parameter information, and then send the formula syntax calculation instructions to the server. The server then performs formula syntax calculations based on the initial instructions to obtain at least one formula syntax corresponding to the formula parameter information. This method decouples the user input function from the formula syntax calculation function, achieving universality and reusability of formula syntax-related functions by calculating formula syntax on the server side. It also avoids browser lag issues caused by complex formula syntax calculations. Finally, the method receives and displays at least one formula syntax sent by the server, significantly improving the user's formula editing experience. Attached Figure Description
[0022] To more clearly illustrate the technical solutions in this application or related technologies, the drawings used in the description of the embodiments or related technologies will be briefly introduced below. Obviously, the drawings described below are only embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0023] Figure 1 This is a schematic diagram illustrating an application scenario of an embodiment of this application;
[0024] Figure 2 This is a flowchart of the formula editing processing method according to an embodiment of this application;
[0025] Figure 3 This is a flowchart of the formula syntax calculation method according to an embodiment of this application;
[0026] Figure 4 This is a structural block diagram of the formula editing processing device according to an embodiment of this application;
[0027] Figure 5 This is a structural block diagram of the formula syntax calculation device according to an embodiment of this application;
[0028] Figure 6 This is a schematic diagram of the structure of an electronic device according to an embodiment of this application. Detailed Implementation
[0029] 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.
[0030] The principles and spirit of this application will now be described with reference to several exemplary embodiments. It should be understood that these embodiments are provided merely to enable those skilled in the art to better understand and implement this application, and are not intended to limit the scope of this application in any way. Rather, these embodiments are provided to make this application more thorough and complete, and to fully convey the scope of this application to those skilled in the art.
[0031] In this application, it should be understood that any number of elements in the accompanying drawings is for illustrative purposes and not for limitation, and any naming is for distinction only and has no limiting meaning.
[0032] Based on the above background description, the following situations also exist in the related technologies:
[0033] Some formula syntax-related features in the formula editor, such as function completion, function parameter hints, and bracket matching, are directly coupled to the online database table on which the formula editor resides. These features are specifically designed and implemented for online database tables and lack general applicability and reusability. Furthermore, complex calculations can cause the main page thread to lag in the browser running the formula editor.
[0034] Based on the above description, the principles and spirit of this application will be explained in detail below with reference to several representative embodiments.
[0035] This application provides a formula editing and processing method, a formula syntax calculation method, and related equipment. It decouples the user input function from the formula syntax calculation function, and realizes the universality and reusability of formula syntax-related functions by calculating formula syntax on the server side. It can also avoid the problem of browser lag caused by complex formula syntax calculations.
[0036] refer to Figure 1 This diagram illustrates an application scenario of the formula editing and processing method and formula syntax calculation method provided in this application embodiment. The application scenario includes a terminal device 101, a server 102, and a data storage system 103. The terminal device 101, server 102, and data storage system 103 can all be connected via wired or wireless communication networks. The terminal device 101 includes, but is not limited to, desktop computers, mobile phones, mobile computers, tablet computers, media players, smart wearable devices, personal digital assistants (PDAs), or other electronic devices capable of performing the aforementioned functions. The server 102 and data storage system 103 can both be independent physical servers, server clusters or distributed systems composed of multiple physical servers, or cloud servers providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms.
[0037] The user inputs formula parameter information into terminal device 101, generating a formula syntax calculation instruction corresponding to the formula parameter information. This instruction is then sent to server 102. Server 102 performs formula syntax calculations based on the initial instruction, obtaining at least one formula syntax corresponding to the formula parameter information. This at least one formula syntax is then fed back to terminal device 101, where it is displayed. Data storage system 103 provides data storage support for the operation of server 102, for example, storing the program code that implements the formula syntax calculation process based on the initial instruction.
[0038] The following is combined with Figure 1 The application scenarios described above illustrate the formula editing and processing method and the formula syntax calculation method according to exemplary embodiments of this application. It should be noted that the above application scenarios are merely shown to facilitate understanding of the spirit and principles of this application, and the embodiments of this application are not limited in any way in this regard. On the contrary, the embodiments of this application can be applied to any applicable scenario.
[0039] This application provides a formula editing method, such as... Figure 2 As shown, it includes:
[0040] Step 201: Receive the input formula parameter information in the formula editing area of the database table, and generate formula syntax calculation instructions corresponding to the formula parameter information.
[0041] In some embodiments, formula parameter information represents relevant information about the formula, including but not limited to functions, operators used for calculation (addition, subtraction, multiplication, division), auxiliary operation symbols (various types of parentheses in the formula), and data used for calculation.
[0042] The formula editor on the client side is split into two modules: the editor and the formula syntax module. The editor responds to the formula parameter information entered by the user, and the formula syntax module listens for changes in the editor, such as changes in the formula parameter information entered by the user and / or changes in the cursor, and generates formula syntax calculation instructions corresponding to the formula parameter information.
[0043] In some embodiments, step 201, generating the formula syntax calculation instruction corresponding to the formula parameter information, includes:
[0044] Step A1: Obtain the formula parameter information in the formula editing area through the formula syntax function, and determine the formula syntax function information corresponding to the formula parameter information.
[0045] Step A2: Generate the formula syntax calculation instruction based on the formula parameter information and the formula syntax function information.
[0046] In some embodiments, formula syntax function information indicates the type of function for which formula syntax needs to be calculated, including but not limited to function completion, function parameter hints, and bracket matching.
[0047] The formula syntax function information corresponding to the formula parameter information is determined. For example, if the formula parameter information entered by the user is part of a function, the formula syntax function information is function completion; if the formula parameter information entered by the user is parentheses in the formula, the formula syntax function information is parentheses matching. Then, formula syntax calculation instructions are generated based on the formula parameter information and the formula syntax function information. The formula syntax calculation instructions include, but are not limited to, the formula parameter information and the formula syntax function information.
[0048] In some embodiments, in response to determining that the formula parameter information is a function to be completed;
[0049] In step 201, generating the formula syntax calculation instruction corresponding to the formula parameter information includes:
[0050] Step B1: Obtain the function completion information corresponding to the function to be completed.
[0051] Step B2: Generate the formula syntax calculation instruction based on the function to be completed and the function completion information.
[0052] In some embodiments, when the formula parameter information is a function to be completed, such as the function to be completed being S, the function completion information is obtained so that the server can know what type of formula syntax to respond to, and thus find all functions containing S through the server.
[0053] Generate formula syntax calculation instructions based on the function to be completed and the function completion information. These formula syntax calculation instructions include, but are not limited to, the function to be completed and the function completion information.
[0054] In some embodiments, in response to determining that the formula parameter information is a series of operational auxiliary symbols;
[0055] In step 201, generating the formula syntax calculation instruction corresponding to the formula parameter information includes:
[0056] Step C1: Receive a target operation auxiliary symbol selection instruction and obtain operation auxiliary symbol matching information corresponding to the target operation auxiliary symbol, wherein the target operation auxiliary symbol is any operation auxiliary symbol among the various operation auxiliary symbols.
[0057] Step C2: Obtain the position of the target operation auxiliary symbol.
[0058] Step C3: Generate the formula syntax calculation instruction based on the target operation auxiliary symbol, the position of the target operation auxiliary symbol, and the operation auxiliary symbol matching information.
[0059] In some embodiments, each operation auxiliary symbol represents various types of parentheses in the formula, such as “()”, “{}”, and “[]”. There may be multiple pairs of the same type of parentheses, such as multiple pairs of “()”.
[0060] When the formula parameter information is the various operation auxiliary symbols in the formula, the target operation auxiliary symbol selection instruction is received. For example, if the target operation auxiliary symbol selection instruction is to select "(" as the target operation auxiliary symbol, then the bracket matching information (i.e. operation auxiliary symbol matching information) is obtained. In order for the server to know what kind of formula syntax function type to respond to, the server can accurately match the operation auxiliary symbol ")" corresponding to the target operation auxiliary symbol "(".
[0061] Obtain the position of the target operation auxiliary symbol "(", or the cursor position corresponding to the target operation auxiliary symbol "(", and generate formula syntax calculation instructions based on the target operation auxiliary symbol, the position of the target operation auxiliary symbol, and the operation auxiliary symbol matching information. Here, the formula syntax calculation instructions include, but are not limited to, the target operation auxiliary symbol, the position of the target operation auxiliary symbol, and the operation auxiliary symbol matching information.
[0062] Step 202: Send the formula syntax calculation instruction to the server so that the server can perform formula syntax calculation according to the initial formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information.
[0063] In some embodiments, a formula syntax calculation instruction is sent to the server, enabling the server to respond to the instruction and perform formula syntax calculations. This results in at least one formula syntax corresponding to the formula parameter information being obtained on the server. The implementation of formula syntax-related functions is converged on the server side for calculation, successfully decoupling the editor and the formula syntax module. At the same time, the method of calculating formula syntax on the server side achieves the universality and reusability of formula syntax-related functions, and avoids the problem of browser lag caused by complex calculations of formula syntax.
[0064] Step 203: Receive at least one formula syntax sent by the server and display the formula syntax.
[0065] In some embodiments, the formula syntax module receives at least one formula syntax returned by the server and displays the formula syntax. For example, if the formula parameter information is S, the formula syntax returned by the server is all functions containing S, such as SUM (summation function), SUMIF (single condition summation function), and SUMPRODUCT (summation statistical function).
[0066] In some embodiments, multiple formula syntaxes are received from the server;
[0067] In step 203, after displaying the formula syntax, the following is also included:
[0068] Step D1: Receive a target formula syntax selection instruction, wherein the target formula syntax is any one of the plurality of formula syntaxes.
[0069] Step D2: Display the target formula syntax and hide other formula syntaxes besides the target formula syntax.
[0070] In some embodiments, the server sends multiple formula syntaxes. After receiving the multiple formula syntaxes, it receives a target formula syntax selection instruction. For example, if the multiple formula syntaxes are SUM, SUMIF, and SUMPRODUCT, and the target formula syntax is SUMIF according to the target formula syntax selection instruction, then only the target formula syntax SUMIF is displayed, and SUM and SUMPRODUCT are hidden.
[0071] Based on the same inventive concept, embodiments of this application propose a formula syntax calculation method, such as... Figure 3 As shown, it includes:
[0072] Step 301: Receive the formula calculation instruction sent by the client.
[0073] Step 302: Perform formula syntax calculation according to the formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information, and send the at least one formula syntax to the client.
[0074] In some embodiments, the server receives a formula syntax calculation instruction sent by the client. In order for the server to know what type of formula syntax function to respond to based on the formula syntax calculation instruction, the server performs formula syntax calculation based on the formula syntax instruction to obtain at least one formula syntax corresponding to the formula parameter information, and feeds back the at least one formula syntax calculated by the server to the client.
[0075] By converging all formula syntax-related functions to server-side calculations, the editor and formula syntax module are successfully decoupled. At the same time, by calculating formula syntax on the server side, the universality and reusability of formula syntax-related functions are achieved, and the problem of browser lag caused by complex formula syntax calculations can be avoided.
[0076] In some embodiments, in response to determining that the formula parameter information is a function to be completed;
[0077] In step 302, the step of performing formula syntax calculation according to the formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information includes:
[0078] Select the function corresponding to the function to be completed from the database pre-stored in the server, obtain at least one completion function corresponding to the function to be completed, and use the completion function as the formula syntax.
[0079] In some embodiments, the database pre-stored on the server includes multiple completion functions. For example, the function to be completed is S. The database includes multiple completion functions that include the function to be completed S. For example, the completed functions that include S are SUM, SUMIF, and SUMPRODUCT. SUM, SUMIF, and SUMPRODUCT are used as formula syntax.
[0080] In some embodiments, in response to determining that the formula parameter information is various operational auxiliary symbols, the formula syntax calculation instruction includes at least one of the following:
[0081] The target operation auxiliary symbol and the position of the target operation auxiliary symbol, wherein the target operation auxiliary symbol is any one of the operation auxiliary symbols;
[0082] In step 302, the step of performing formula syntax calculation according to the formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information includes:
[0083] Step E1: Based on the target operation auxiliary symbol and its position, perform operation auxiliary symbol matching between the target operation auxiliary symbol and each of the operation auxiliary symbols to obtain at least one matching operation auxiliary symbol corresponding to the target operation auxiliary symbol.
[0084] Step E2: Obtain the position of the matching operation auxiliary symbol, and use the matching operation auxiliary symbol and its position as the formula syntax.
[0085] In some embodiments, when the formula parameter information is various operation auxiliary symbols, for example, the formula parameter information is various types of brackets, such as “()”, “{}”, “[]”, where there may be multiple pairs of brackets of the same type, such as multiple pairs of “()”.
[0086] The formula syntax instructions include, but are not limited to, the target operation auxiliary symbol and the position of the target operation auxiliary symbol, for example, the target operation auxiliary symbol is ")".
[0087] Based on the position of the target operation auxiliary symbol ")", the operation auxiliary symbol is matched with each operation auxiliary symbol, and the operation auxiliary symbol "("" corresponding to the target operation auxiliary symbol ")" is accurately matched by the server.
[0088] Get the position of the auxiliary operation symbol "(", and use the auxiliary operation symbol "(" and its position as formula syntax to highlight the auxiliary operation symbol "(" on the client side.
[0089] The above scheme receives input formula parameter information in the formula editing area of the database table, generates formula syntax calculation instructions corresponding to the formula parameter information, and then sends the formula syntax calculation instructions to the server. The server then performs formula syntax calculations based on the initial instructions to obtain at least one formula syntax corresponding to the formula parameter information. This decouples the user input function from the formula syntax calculation function, achieving versatility and reusability of formula syntax-related functions by calculating formula syntax on the server side. It also avoids browser lag issues caused by complex formula syntax calculations. Finally, it receives and displays at least one formula syntax sent from the server, significantly improving the user's formula editing experience.
[0090] This application describes the formula editing process in detail with an example, as follows:
[0091] Initialize the formula syntax service and connect the client and server: By initializing the formula syntax service, a connection is created between the client and the server, and the syntax service functions to be enabled (i.e., formula syntax function information) are declared.
[0092] 1. Initialize the formula syntax service (i.e., the server).
[0093] 2. Initialize the formula editor (i.e., the client).
[0094] 3. Connect the server and the client.
[0095] 4. After connection, the client sends initialization information (i.e. formula syntax calculation instructions) and declares the formula syntax functions to be enabled (i.e. formula syntax function information).
[0096] The formula syntax service is requested according to the LSP (Layered Service Provider) protocol. The formula syntax function module responds to changes in the cursor or content (i.e., formula parameter information), determines the formula syntax function to be requested (i.e., formula syntax function information), generates the corresponding request data (i.e., formula syntax calculation instructions), and sends it to the server.
[0097] For example, when a user enters S (the function to be completed), the formula editor responds with changes in the text and the cursor.
[0098] The formula syntax module monitors text and cursor changes, requires function completion (i.e., function completion information), and generates the data needed for the function completion syntax service request (function completion request data, function declaration content, and cursor position) (i.e., formula syntax calculation instructions).
[0099] The client-side equation editor (i.e., the client) sends the requested data to the syntax service server (i.e., the server).
[0100] Asynchronous request for data completes, response data changes:
[0101] After the formula syntax is calculated, the data (i.e., the formula syntax) is returned to the formula editor client (i.e., the client).
[0102] Update the formula editor based on the response data (i.e., formula syntax) (get completion information, expand the completion suggestion list in the formula editor) (i.e. complete the function).
[0103] The formula editor adopts a C / S (Client-Serve) architecture, converging all formula syntax-related functions to be calculated on the server side. At the same time, the front-end formula editor is transformed into a client to send requests to the server after responding to user interactions. After the server performs the calculation, the client asynchronously obtains the returned response data and updates the formula editor accordingly.
[0104] By using a client / server architecture in the formula editor, not only are the editor and formula syntax modules successfully decoupled, but the asynchronous running mode also avoids blocking the browser UI thread (the main thread of application execution), reducing browser lag issues and greatly improving the user's formula editing experience.
[0105] It should be noted that the method in this embodiment can be executed by a single device, such as a computer or server. The method can also be applied in a distributed scenario, where multiple devices cooperate to complete the task. In such a distributed scenario, one of these devices may execute only one or more steps of the method in this embodiment, and the multiple devices will interact with each other to complete the method described.
[0106] It should be noted that the above description describes some embodiments of this application. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in a different order than that shown in the above embodiments and still achieve the desired result. Furthermore, the processes depicted in the drawings do not necessarily require a specific or sequential order to achieve the desired result. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0107] Based on the same inventive concept, corresponding to the formula editing processing method of any of the above embodiments, this application also provides a formula editing processing device.
[0108] refer to Figure 4 The formula editing processing device includes:
[0109] The instruction generation module 401 is configured to receive input formula parameter information in the formula editing area of the database table and generate formula syntax calculation instructions corresponding to the formula parameter information.
[0110] The instruction sending module 402 is configured to send the formula syntax calculation instruction to the server so that the server performs formula syntax calculation according to the initial formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information.
[0111] Display module 403 is configured to receive at least one formula syntax sent by the server and display the formula syntax.
[0112] In some embodiments, the instruction generation module 401 is specifically configured as follows:
[0113] The formula parameter information in the formula editing area is obtained through the formula syntax function, and the formula syntax function information corresponding to the formula parameter information is determined.
[0114] The formula syntax calculation instruction is generated based on the formula parameter information and the formula syntax function information.
[0115] In some embodiments, in response to determining that the formula parameter information is a function to be completed;
[0116] Instruction generation module 401 is specifically configured as follows:
[0117] Obtain the function completion information corresponding to the function to be completed;
[0118] The formula syntax calculation instruction is generated based on the function to be completed and the function completion information.
[0119] In some embodiments, in response to determining that the formula parameter information is a series of operational auxiliary symbols;
[0120] Instruction generation module 401 is specifically configured as follows:
[0121] Receive a target operation auxiliary symbol selection instruction, and obtain operation auxiliary symbol matching information corresponding to the target operation auxiliary symbol, wherein the target operation auxiliary symbol is any operation auxiliary symbol among the various operation auxiliary symbols;
[0122] Obtain the position of the target operation auxiliary symbol;
[0123] The formula syntax calculation instruction is generated based on the target operation auxiliary symbol, the position of the target operation auxiliary symbol, and the matching information of the operation auxiliary symbol.
[0124] In some embodiments, multiple formula syntaxes are received from the server;
[0125] The formula editing processing device also includes a hidden module, specifically configured as follows:
[0126] Receive a target formula syntax selection instruction, wherein the target formula syntax is any one of the plurality of formula syntaxes;
[0127] Display the target formula syntax and hide other formula syntaxes besides the target formula syntax.
[0128] Based on the same inventive concept, a formula syntax calculation device corresponding to the formula syntax calculation method of the above embodiments, such as... Figure 5 As shown, it includes:
[0129] The instruction receiving module 501 is configured to receive formula calculation instructions sent by the client;
[0130] The formula syntax calculation module 502 is configured to perform formula syntax calculation according to the formula syntax calculation instruction, obtain at least one formula syntax corresponding to the formula parameter information, and send the at least one formula syntax to the client.
[0131] In some embodiments, in response to determining that the formula parameter information is a function to be completed;
[0132] Formula syntax calculation module 502 is specifically configured as follows:
[0133] Select the function corresponding to the function to be completed from the database pre-stored in the server, obtain at least one completion function corresponding to the function to be completed, and use the completion function as the formula syntax.
[0134] In some embodiments, in response to determining that the formula parameter information is various operational auxiliary symbols, the formula syntax calculation instruction includes at least one of the following:
[0135] The target operation auxiliary symbol and the position of the target operation auxiliary symbol, wherein the target operation auxiliary symbol is any one of the operation auxiliary symbols;
[0136] Formula syntax calculation module 502 is specifically configured as follows:
[0137] Based on the target operation auxiliary symbol and its position, the target operation auxiliary symbol is matched with each of the operation auxiliary symbols to obtain at least one matching operation auxiliary symbol corresponding to the target operation auxiliary symbol;
[0138] Obtain the position of the matching operation auxiliary symbol, and use the matching operation auxiliary symbol and its position as the formula syntax.
[0139] For ease of description, the above devices are described in terms of function, divided into various modules. Of course, in implementing this application, the functions of each module can be implemented in one or more software and / or hardware.
[0140] The apparatus of the above embodiments is used to implement the corresponding method in any of the foregoing embodiments and has the beneficial effects of the corresponding method embodiments, which will not be repeated here.
[0141] Based on the same inventive concept, corresponding to the methods of any of the above embodiments, this application also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the methods described in any of the above embodiments.
[0142] Figure 6 This embodiment illustrates a more specific hardware structure of an electronic device, which may include a processor 601, a memory 602, an input / output interface 603, a communication interface 604, and a bus 605. The processor 601, memory 602, input / output interface 603, and communication interface 604 are interconnected internally via the bus 605.
[0143] The processor 601 can be implemented using a general-purpose CPU (Central Processing Unit), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this specification.
[0144] The memory 602 can be implemented in the form of ROM (Read-Only Memory), RAM (Random Access Memory), static storage device, dynamic storage device, etc. The memory 602 can store the operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented by software or firmware, the relevant program code is stored in the memory 602 and is called and executed by the processor 601.
[0145] The input / output interface 603 is used to connect input / output modules to realize information input and output. Input / output modules can be configured as components within the device (not shown in the figure) or externally connected to the device to provide corresponding functions. Input devices may include keyboards, mice, touchscreens, microphones, various sensors, etc., while output devices may include displays, speakers, vibrators, indicator lights, etc.
[0146] Communication interface 604 is used to connect a communication module (not shown in the figure) to enable communication between this device and other devices. The communication module can communicate via wired means (such as USB, Ethernet cable, etc.) or wireless means (such as mobile network, WIFI, Bluetooth, etc.).
[0147] Bus 605 includes a pathway for transmitting information between various components of the device (e.g., processor 601, memory 602, input / output interface 603, and communication interface 604).
[0148] It should be noted that although the above-described device only shows the processor 601, memory 602, input / output interface 603, communication interface 604, and bus 605, in specific implementations, the device may also include other components necessary for normal operation. Furthermore, those skilled in the art will understand that the above-described device may only include the components necessary for implementing the embodiments of this specification, and not necessarily all the components shown in the figures.
[0149] The electronic devices described above are used to implement the corresponding formula editing processing method or formula syntax calculation method in any of the foregoing embodiments, and have the beneficial effects of the corresponding formula editing processing method or formula syntax calculation method embodiments, which will not be repeated here.
[0150] Based on the same inventive concept, corresponding to the methods of any of the above embodiments, this application also provides a non-transitory computer-readable storage medium that stores computer instructions for causing the computer to perform the methods described in any of the above embodiments.
[0151] The computer-readable medium of this embodiment includes permanent and non-permanent, removable and non-removable media, and information storage can be implemented by any method or technology. Information can be computer-readable instructions, data structures, program modules, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transfer medium that can be used to store information accessible by a computing device.
[0152] The computer instructions stored in the storage medium of the above embodiments are used to cause the computer to perform the method described in any of the above embodiments, and have the beneficial effects of the corresponding method embodiments, which will not be repeated here.
[0153] Those skilled in the art should understand that the discussion of any of the above embodiments is merely exemplary and is not intended to imply that the scope of this application (including the claims) is limited to these examples; within the framework of this application, the technical features of the above embodiments or different embodiments can also be combined, the steps can be implemented in any order, and there are many other variations of different aspects of the embodiments of this application as described above, which are not provided in the details for the sake of brevity.
[0154] Additionally, to simplify the description and discussion, and to avoid obscuring the embodiments of this application, the well-known power / ground connections to integrated circuit (IC) chips and other components may or may not be shown in the provided drawings. Furthermore, the apparatus may be shown in block diagram form to avoid obscuring the embodiments of this application, and this also takes into account the fact that the details of the implementation of these block diagram apparatuses are highly dependent on the platform on which the embodiments of this application will be implemented (i.e., these details should be fully understood by those skilled in the art). While specific details (e.g., circuits) have been set forth to describe exemplary embodiments of this application, it will be apparent to those skilled in the art that the embodiments of this application can be implemented without these specific details or with variations thereof. Therefore, these descriptions should be considered illustrative rather than restrictive.
[0155] Although this application has been described in conjunction with specific embodiments thereof, many substitutions, modifications, and variations of these embodiments will be apparent to those skilled in the art from the foregoing description. For example, other memory architectures (e.g., dynamic RAM (DRAM)) may be used with the embodiments discussed.
[0156] The embodiments of this application are intended to cover all such substitutions, modifications, and variations that fall within the broad scope of the appended claims. Therefore, any omissions, modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the embodiments of this application should be included within the protection scope of this application.
Claims
1. A formula editing processing method characterized by comprising: The method includes: Receiving input formula parameter information in the formula editing area of a database table and generating formula syntax calculation instructions corresponding to the formula parameter information includes: obtaining formula parameter information in the formula editing area through formula syntax functions and determining formula syntax function information corresponding to the formula parameter information; generating the formula syntax calculation instructions based on the formula parameter information and the formula syntax function information. In response to determining that the formula parameter information is various operational auxiliary symbols, the step of generating a formula syntax calculation instruction corresponding to the formula parameter information includes: receiving a target operational auxiliary symbol selection instruction; obtaining operational auxiliary symbol matching information corresponding to the target operational auxiliary symbol, wherein the target operational auxiliary symbol is any one of the various operational auxiliary symbols; obtaining the position of the target operational auxiliary symbol; and generating the formula syntax calculation instruction based on the target operational auxiliary symbol, the position of the target operational auxiliary symbol, and the operational auxiliary symbol matching information. Send the formula syntax calculation instruction to the server so that the server can perform formula syntax calculation according to the formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information; Receive at least one formula syntax sent by the server and display the formula syntax; Receive a target formula syntax selection instruction, wherein the target formula syntax is any one of the at least one formula syntaxes; Display the target formula syntax and hide other formula syntaxes besides the target formula syntax.
2. The method of claim 1, wherein, In response to determining that the formula parameter information is a function to be completed; The generation of formula syntax calculation instructions corresponding to the formula parameter information includes: Obtain the function completion information corresponding to the function to be completed; The formula syntax calculation instruction is generated based on the function to be completed and the function completion information.
3. A method of formula grammar computation, characterized by, include: The system receives formula syntax calculation instructions sent by the client; wherein, the generation of the formula syntax calculation instructions includes: obtaining formula parameter information in the formula editing area through the formula syntax function, and determining the formula syntax function information corresponding to the formula parameter information; generating the formula syntax calculation instructions based on the formula parameter information and the formula syntax function information. In response to determining that the formula parameter information is various operational auxiliary symbols, the step of generating a formula syntax calculation instruction corresponding to the formula parameter information includes: receiving a target operational auxiliary symbol selection instruction; obtaining operational auxiliary symbol matching information corresponding to the target operational auxiliary symbol, wherein the target operational auxiliary symbol is any one of the operational auxiliary symbols; obtaining the position of the target operational auxiliary symbol; generating the formula syntax calculation instruction based on the target operational auxiliary symbol, the position of the target operational auxiliary symbol, and the operational auxiliary symbol matching information; performing formula syntax calculation based on the formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information, and sending the at least one formula syntax to the client for display on the client; and displaying the target formula syntax based on the target formula syntax selection instruction, while hiding other formula syntaxes besides the target formula syntax, wherein the target formula syntax is any one of the at least one formula syntaxes.
4. The method of claim 3, wherein, In response to determining that the formula parameter information is a function to be completed; The step of performing formula syntax calculation according to the formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information includes: Select the function corresponding to the function to be completed from the database pre-stored on the server, obtain at least one completion function corresponding to the function to be completed, and use the completion function as the formula syntax.
5. The method according to claim 3, characterized in that, The formula syntax calculation instructions include at least one of the following: the target operation auxiliary symbol and the position of the target operation auxiliary symbol; The step of performing formula syntax calculation according to the formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information includes: Based on the target operation auxiliary symbol and its position, the target operation auxiliary symbol is matched with each of the operation auxiliary symbols to obtain at least one matching operation auxiliary symbol corresponding to the target operation auxiliary symbol; Obtain the position of the matching operation auxiliary symbol, and use the expression including the matching operation auxiliary symbol and its position as the formula syntax.
6. A formula editing processing device characterized by comprising: include: The instruction generation module is configured to receive input formula parameter information in the formula editing area of a database table, and generate a formula syntax calculation instruction corresponding to the formula parameter information, including: obtaining the formula parameter information in the formula editing area through the formula syntax function, and determining the formula syntax function information corresponding to the formula parameter information; generating the formula syntax calculation instruction based on the formula parameter information and the formula syntax function information. In response to determining that the formula parameter information is various operational auxiliary symbols, the step of generating a formula syntax calculation instruction corresponding to the formula parameter information includes: receiving a target operational auxiliary symbol selection instruction; obtaining operational auxiliary symbol matching information corresponding to the target operational auxiliary symbol, wherein the target operational auxiliary symbol is any one of the various operational auxiliary symbols; obtaining the position of the target operational auxiliary symbol; and generating the formula syntax calculation instruction based on the target operational auxiliary symbol, the position of the target operational auxiliary symbol, and the operational auxiliary symbol matching information. The instruction sending module is configured to send the formula syntax calculation instruction to the server so that the server performs formula syntax calculation according to the formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information. The display module is configured to receive at least one formula syntax sent by the server and display the formula syntax; receive a target formula syntax selection instruction, wherein the target formula syntax is any one of the at least one formula syntax; display the target formula syntax and hide other formula syntaxes other than the target formula syntax.
7. A formula syntax calculating apparatus characterized by comprising: include: The instruction receiving module is configured to receive formula syntax calculation instructions sent by the client; wherein, the generation of the formula syntax calculation instructions includes: obtaining formula parameter information in the formula editing area through the formula syntax function, and determining the formula syntax function information corresponding to the formula parameter information; generating the formula syntax calculation instructions based on the formula parameter information and the formula syntax function information. In response to determining that the formula parameter information is various operational auxiliary symbols, the step of generating a formula syntax calculation instruction corresponding to the formula parameter information includes: receiving a target operational auxiliary symbol selection instruction; obtaining operational auxiliary symbol matching information corresponding to the target operational auxiliary symbol, wherein the target operational auxiliary symbol is any one of the various operational auxiliary symbols; obtaining the position of the target operational auxiliary symbol; and generating the formula syntax calculation instruction based on the target operational auxiliary symbol, the position of the target operational auxiliary symbol, and the operational auxiliary symbol matching information. The formula syntax calculation module is configured to perform formula syntax calculation according to the formula syntax calculation instruction to obtain at least one formula syntax corresponding to the formula parameter information, and send the at least one formula syntax to the client for display on the client, and display the target formula syntax based on the target formula syntax selection instruction, and hide other formula syntaxes other than the target formula syntax, wherein the target formula syntax is any one of the at least one formula syntaxes.
8. An electronic device comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the method as described in any one of claims 1 to 5.
9. A non-transitory computer-readable storage medium storing computer instructions, wherein, The computer instructions are used to cause the computer to perform the method according to any one of claims 1 to 5.