Table adjustment method, device, electronic device, medium and program

By displaying table correction controls and correction instructions to adjust the table header area, the problems of low table adjustment efficiency and complex operation in the prior art are solved, and convenient and accurate table processing and efficient data query are achieved.

CN114564926BActive Publication Date: 2025-09-16ZHUHAI KINGSOFT OFFICE SOFTWARE +2
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210167216.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-02-23
Publication Date
2025-09-16
Estimated Expiration
2042-02-23

AI Technical Summary

Technical Problem

In the prior art, table adjustment is inefficient and complex to operate, and users need to modify and adjust the table themselves so that the server can accurately parse it, resulting in a poor user experience.

Method used

A table adjustment method is provided. By displaying the target table and the header area correction control, correction instructions are obtained, the header area is adjusted according to the row identifier or column identifier, and the adjusted table is generated and displayed. It supports parsing data records on the query server.

Benefits of technology

Conveniently and accurately determine the table header and body areas, avoiding the tedious operation of users modifying and re-uploading the table, and improving user experience and query efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114564926B_ABST
    Figure CN114564926B_ABST
Patent Text Reader

Abstract

The present invention relates to a table adjustment method, device, electronic device, medium and program, the method comprising: displaying a target table and a header area correction control corresponding to the target table; obtaining a correction instruction; in response to the correction instruction, obtaining an adjusted header area according to a row identifier or a column identifier contained in the correction instruction; generating and displaying an adjusted target table based on the adjusted header area. The present invention facilitates users to conveniently input correction instructions for adjusting the header area by displaying the target table and the header area control corresponding to the target table; adjusting the header area range through the correction instruction accurately determines the header area of ​​the target table. The present invention conveniently and accurately determines the header and body areas of the table, avoiding the tedious operation of users modifying and uploading the table again, thereby improving the user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of data processing technology, and in particular to a table adjustment method, device, electronic equipment, medium and program. Background Art

[0002] Reverse query refers to the act of granting access authorization to multiple parties, such as the release of exam results, the issuance of payroll slips, and application progress inquiries. In practice, the uploader uploads a form, which the server then parses to determine the header and body. Finally, the server extracts data records based on the attribute information in the header and the specific data in the body, making them available to multiple users.

[0003] However, when a table has a complex header structure (for example, an invalid row in the header) or the header and body are similar, the server cannot accurately parse the table and needs to further adjust the table. In the existing technology, users are usually required to modify and adjust the table themselves and then upload it again for the server to accurately recognize it. The existing technology's table adjustment is inefficient and complex to operate, resulting in a poor user experience.

[0004] To this end, a technical solution to the above-mentioned defects is now urgently needed. Summary of the Invention

[0005] The present invention provides a table adjustment method, device, electronic equipment, medium and program, which are used to solve the defects of low table adjustment efficiency and complex operation in the prior art.

[0006] The present invention provides a table adjustment method, comprising:

[0007] Displaying a target table and a table header area correction control corresponding to the target table; wherein the target table includes a table header area and a table body area;

[0008] Obtaining a correction instruction; wherein the correction instruction is generated based on an operation on the header area correction control, and the correction instruction includes a row identifier or a column identifier for adjusting a range of the header area;

[0009] In response to the correction instruction, obtaining an adjusted header area according to the row identifier or column identifier included in the correction instruction;

[0010] Generate and display the adjusted target table based on the adjusted header area.

[0011] According to a table adjustment method provided by the present invention, after generating and displaying an adjusted target table based on the adjusted table header area, the method further includes:

[0012] Sending the adjusted target table to a query server, so that the query server can parse the adjusted target table and generate a plurality of data records;

[0013] The data records correspond to the fields included in the adjusted header area; the query server is further configured to respond to a data query request with query authority based on the plurality of data records and return corresponding data records.

[0014] According to a table adjustment method provided by the present invention, in response to the correction instruction, obtaining an adjusted table header area according to a row identifier or a column identifier included in the correction instruction includes:

[0015] On the basis of the header area range of the target table, adding or deleting the row corresponding to the row identifier to obtain an adjusted header area;

[0016] or,

[0017] On the basis of the header area range of the target table, adding or deleting the column corresponding to the column identifier to obtain an adjusted header area;

[0018] or,

[0019] In the target table, the row corresponding to the row identifier or the column corresponding to the column identifier is determined as the adjusted table header area.

[0020] According to a table adjustment method provided by the present invention, generating and displaying an adjusted target table based on the adjusted table header area includes:

[0021] removing the area of ​​the target table that is not included in the adjusted table header area and the corresponding adjusted table body area to obtain an adjusted target table;

[0022] The adjusted target table is displayed.

[0023] According to a table adjustment method provided by the present invention, displaying the adjusted target table includes:

[0024] Displaying the header area of ​​the adjusted target table according to the first display mode;

[0025] displaying the adjusted table body area in the target table according to the second display mode;

[0026] The first display mode and the second display mode are different table display modes.

[0027] According to a table adjustment method provided by the present invention, when the target table is in a display state, the data in the target table is in an editable state;

[0028] When the adjusted target table is in a displayed state, the data in the adjusted target table is in an editable state.

[0029] According to a table adjustment method provided by the present invention, before displaying the target table and the table header area correction control corresponding to the target table, the method further includes:

[0030] receiving the target form;

[0031] Determine a header area and a body area of ​​the target table according to the table content in the target table;

[0032] Displaying a header area of ​​the target table according to a third display mode;

[0033] displaying a table body area of ​​the target table according to a fourth display mode;

[0034] The third display mode and the fourth display mode are different table display modes.

[0035] According to a table adjustment method provided by the present invention, determining a header area and a body area of ​​a target table according to table content in the target table includes:

[0036] Traversing the data in the target table, determining an area consisting of all rows containing target keywords in the target table as a header area of ​​the target table, and determining some rows below the header area in the target table as a body area;

[0037] or,

[0038] The data in the target table is traversed, and an area consisting of all columns containing target keywords in the target table is determined as a header area of ​​the target table, and some columns to the right of the header area in the target table are determined as a table body area.

[0039] The present invention also provides a table adjustment device, comprising:

[0040] A first display module is configured to display a target table and a table header area correction control corresponding to the target table; wherein the target table includes a table header area and a table body area;

[0041] an instruction acquisition module, configured to acquire a correction instruction, wherein the correction instruction is generated based on an operation on the header area correction control, and the correction instruction includes a row identifier or a column identifier for adjusting a range of the header area;

[0042] a table correction module, configured to respond to the correction instruction and obtain an adjusted table header area according to a row identifier or a column identifier included in the correction instruction;

[0043] The second display module is configured to generate and display an adjusted target table based on the adjusted table header area.

[0044] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, all or part of the steps of any of the above table adjustment methods are implemented.

[0045] The present invention also provides a computer-readable storage medium having a computer program stored thereon, which implements all or part of the steps of any of the above table adjustment methods when executed by a processor.

[0046] The present invention further provides a computer program product, comprising computer-executable instructions, wherein the instructions are used to implement all or part of the steps of any of the above table adjustment methods when executed.

[0047] The present invention provides a table adjustment method, apparatus, electronic device, medium, and program. By displaying a target table and a corresponding header area control, the user can conveniently input correction instructions for adjusting the header area. The correction instructions are used to adjust the header area range, accurately determining the header area of ​​the target table. The present invention conveniently and accurately determines the header and body areas of a table, avoiding the tedious process of modifying and re-uploading the table, thereby improving the user experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] In order to more clearly illustrate the technical solutions in the present invention or the prior art, a brief introduction is given below to the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0049] Figure 1 This is an example of a salary information table to be adjusted in a payslip issuance scenario;

[0050] Figure 2 It is a flowchart of a table adjustment method provided by the present invention;

[0051] Figure 3 This is a schematic diagram of correcting the header area by checking a box in a table adjustment method provided by the present invention;

[0052] Figure 4This is a schematic diagram of correcting the header area by dragging a selection box in a table adjustment method provided by the present invention;

[0053] Figure 5 For the existing technology Figure 1 Schematic diagram after the table in is adjusted;

[0054] Figure 6 According to the table adjustment method of the present invention Figure 3 Schematic diagram of the table after correction;

[0055] Figure 7 It is a structural schematic diagram of the table adjustment device provided by the present invention;

[0056] Figure 8 It is a structural schematic diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION

[0057] To make the objectives, technical solutions, and advantages of the present invention more clear, the technical solutions of the present invention will be clearly and completely described below in conjunction with the accompanying drawings. Obviously, the embodiments described are only some of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts shall fall within the scope of protection of the present invention.

[0058] Figure 1 This is an example of a salary information table to be adjusted in the payslip issuance scenario, such as Figure 1 As shown, the data in the header area 12 describes the attribute information of the data in the body area 13 of the table. The data in the body area 13 is the specific data corresponding to each attribute information in the header area. For example, Figure 1 The data "AAA, XXXXXXXXX, R&D Department, 20000, 500, 19500" in the table body area 13 corresponds to the attribute information "Name, Mobile Number, Department, Payable, Individual Income Tax, Actual Payment" in the table header area 12.

[0059] In some application scenarios, some information in the table header area will not be used. For example, Figure 1When the salary slip shown is split into individual salary slips, the information such as "MMM Company", "Salary Information Table", "May" in the salary slip is invalid information for the individual. In the present application, this part of the content in the form is divided into an invalid header, represented by the number 11. During the form adjustment process, the data in the invalid header area should be deleted. In the prior art, it is possible to divide the invalid header 11 into a part of the actual header area 12. At this time, the form adjustment can only be achieved manually, removing the invalid header 11, and then uploading the adjusted form to the server again. The form adjustment process of the prior art has the defects of complex operation and easy error.

[0060] In order to solve the problem that the table adjustment efficiency is low and the operation is complicated in the prior art, the present invention provides a table adjustment method, device, electronic device, medium and program. Figures 1-8 The present invention describes a table adjustment method, device, electronic device, medium and program.

[0061] Figure 2 This is a flow chart of a table adjustment method provided by the present invention. Figure 2 As shown, the method includes:

[0062] S21, displaying a target table and a table header area correction control corresponding to the target table; wherein the target table includes a table header area and a table body area;

[0063] Specifically, the table adjustment process of the table adjustment method of the present invention can be executed on a user terminal (such as a PC, mobile phone, PDA, etc.) using an installed table adjustment client. After the table adjustment is completed, the adjustment result is uploaded to the server. The server provides query services to the target group based on the adjustment result (for example, salary slip query, grade query, etc.).

[0064] The target table is the table to be adjusted uploaded by the user, and the target table includes a header area and a table body area. After receiving the first instruction, the target table and the header area correction control corresponding to the target table are displayed by the display device. The display device displays the target table to facilitate the user to understand the status of the target table. The display device also displays the header area correction control corresponding to the target table (a control is an object with which the user can interact to input or operate data) for the user to operate to obtain correction data for the header area, such as the user operating the header area correction control through a touch screen, or the user operating the header area correction control through a keyboard / mouse.

[0065] It should be noted that the action of displaying the target table and the header area correction control corresponding to the target table in this step can be triggered by instructions input by the user. For example, after the user uploads the table, the action of displaying the target table and the header area correction control is triggered by clicking the "OK" button on the interactive interface; it can also be that after the user uploads the target table, the target table and the header area correction control are automatically displayed according to preset program instructions.

[0066] S22. Obtain a correction instruction; wherein the correction instruction is generated based on an operation on the header area correction control, and the correction instruction includes a row identifier or a column identifier for adjusting a range of the header area;

[0067] Specifically, the correction instruction input by the user operating the header area correction control is obtained. The correction instruction includes the row identifier or column identifier required to adjust the range of the header area, which is used to correct the header area of ​​the target table. For example, the user enters the correction instruction by checking the corresponding row in the header area through the "check box". At this time, the correction instruction includes the row identifiers of each checked row. The "row identifier" in the correction instruction can be used to correct the range of the header area, such as adding / deleting rows corresponding to the row identifier based on the header area before adjustment. The row identifier is used to uniquely mark the rows in the target table. For example, the row identifiers corresponding to the rows from top to bottom in the target table are set to 1, 2, 3, 4... in sequence. The column identifier is used to uniquely mark the columns in the target table. For example, the column identifiers corresponding to the columns from left to right in the target table are set to A, B, C, D... in sequence.

[0068] S23. In response to the correction instruction, obtain an adjusted header area according to the row identifier or column identifier included in the correction instruction;

[0069] Specifically, the header area in the target table is adjusted according to the correction instruction, and the adjustment content may be to increase the area range on the basis of the current header area. For example, the current header area is smaller and part of the area is divided into the table body area or the invalid area. At this time, according to the row corresponding to the row identifier in the correction instruction or the column corresponding to the column identifier in the correction instruction, the part is added to the current header area to obtain the adjusted header area; the adjustment content of the correction instruction may also be to delete the area range on the basis of the current header area. For example, the current header area is larger and part of the table body area or the invalid area is divided into the header area. At this time, according to the row corresponding to the row identifier in the correction instruction or the column corresponding to the column identifier in the correction instruction, the part is deleted from the previous header area to obtain the adjusted header area; the adjustment content of the correction instruction may also be to directly redetermine the complete header area, that is, directly determine the row corresponding to the row identifier in the correction instruction or the column corresponding to the column identifier in the correction instruction as the adjusted header area.

[0070] S24: Generate and display an adjusted target table based on the adjusted header area.

[0071] Specifically, the area division of the target table is re-determined based on the adjusted header area, and the adjusted table is displayed through a display device. The display device displays the adjusted header area and table body area, making it convenient for the user to adjust or confirm the adjusted target table state again. After confirming the required target table state, subsequent table parsing can be performed. Table parsing is to extract the data in the table and the corresponding attribute information in the header area for query by the target group of users. It can be understood that after the above-mentioned header adjustment, the parsing error rate of the target table will be greatly reduced.

[0072] This embodiment displays the target table and the corresponding header area controls, allowing the user to conveniently enter correction instructions for adjusting the header area. The correction instructions adjust the header area range, accurately determining the target table's header area. This invention conveniently and accurately determines the table's header and body areas, avoiding the tedious process of modifying and re-uploading the table, thereby improving the user experience.

[0073] Based on any of the above embodiments, in one embodiment, after generating and displaying an adjusted target table based on the adjusted table header area, the method further includes:

[0074] Sending the adjusted target table to the query server, so that the query server parses the adjusted target table and generates multiple data records;

[0075] The data records correspond to the fields included in the adjusted header area; the query server is further configured to respond to a data query request with query authority based on the plurality of data records and return corresponding data records.

[0076] Specifically, the process of adjusting the target table in the present invention can be executed multiple times. For example, after the user adjusts the target table for the first time, the method can be executed again or multiple times to determine whether the adjusted target table reaches the state required by the user. The user terminal also sends the adjusted target table to the query server for the query server to parse the adjusted target table and generate multiple data records for query. The data records correspond to the fields contained in the adjusted header area. For example, for grade query, each data record corresponds to the "name, student number, Chinese, mathematics, English..." and other contents contained in the adjusted header area. For example, for salary slip query, each data record corresponds to the "name, mobile phone number, department, payable salary..." and other contents contained in the adjusted header area. After receiving the query request of the query user, the query server performs identity authentication on the query user. If the authentication is successful, it is determined that the query user has the query authority and returns the data record corresponding to the query user.

[0077] In this embodiment, the adjusted target table is sent to the query server, which facilitates the query server to accurately and efficiently parse out data records for query users, thereby improving the efficiency and accuracy of reverse query.

[0078] Based on any of the above embodiments, in one embodiment, in response to the correction instruction, obtaining the adjusted header area according to the row identifier or column identifier included in the correction instruction includes:

[0079] Based on the header area range of the target table, add or delete rows corresponding to the row identifiers to obtain an adjusted header area;

[0080] or,

[0081] Based on the header area range of the target table, add or delete columns corresponding to the column identifiers to obtain an adjusted header area;

[0082] or,

[0083] In the target table, the row corresponding to the row identifier or the column corresponding to the column identifier is determined as the adjusted table header area.

[0084] Specifically, due to different table usage habits, there may be horizontal headers (i.e., using the "rows" in the target table as headers) and vertical headers (i.e., using the "columns" in the target table as headers).

[0085] For a horizontal table header, the process of adjusting the table header area may be to add or delete rows corresponding to row identifiers in the correction instruction based on the table header area range of the target table, thereby obtaining an adjusted table header area; for a vertical table header, the process of adjusting the table header area may be to add or delete columns corresponding to column identifiers in the correction instruction based on the table header area range of the target table, thereby obtaining an adjusted table header area;

[0086] In addition, the process of adjusting the header area can also be to directly redefine the header area. This process does not add or delete the corresponding area based on the original header area, but directly determines the row corresponding to the row identifier in the correction instruction, or the column corresponding to the column identifier as the adjusted header area.

[0087] In this embodiment, the header area is accurately determined based on the row identifier or column identifier used to adjust the range of the header area in the correction instruction, and the table is corrected efficiently.

[0088] Based on any of the above embodiments, in one embodiment, after obtaining the adjusted header area, the method further includes:

[0089] The portion outside the adjusted header area that faces the pre-adjusted body area is determined as the post-adjusted body area.

[0090] Specifically, in the process of adjusting the header area, part of the body area may be divided into the header area, or part of the header area may be divided into the body area. Invalid rows or columns (i.e., invalid headers) may also be removed from the header area. Accordingly, after adjusting the header area, the body area also needs to be adjusted. The part outside the adjusted header area that faces the body area before adjustment is determined as the adjusted body area. That is, the body area is adjusted accordingly based on the header area, and the invalid header is excluded. For example, still referring to Figure 1 Before adjustment, area 11 and area 12 are determined as the header area. The correction instruction determines area 12 as the adjusted header area. At this time, the part outside the adjusted header area includes area 11 and area 13. Among them, area 11 is away from the body area before adjustment relative to area 12, and area 13 is towards the body area before adjustment relative to area 12. Therefore, area 13 is determined as the body area after adjustment. It can be understood that for the case where the header area adjustment does not involve the body area, for example Figure 1 , the surface area before and after adjustment is consistent.

[0091] In this embodiment, after obtaining the adjusted table header area, the table body area is accurately adjusted accordingly, thereby reducing the parsing error rate of the target table.

[0092] Based on any of the above embodiments, in one embodiment, the header area correction control includes at least one of the following: a check box, a row identifier input text box, a column identifier input text box, a drag box, and a slider.

[0093] Specifically, the header area correction control can be presented in a variety of ways. For example, the header area correction control can be in the form of a check box. Figure 3 This is a schematic diagram of correcting the header area by checking a box in a table adjustment method provided by the present invention. Figure 3 As shown, the user can select the header area range by adding and checking the corresponding rows or columns; the header area correction control can be in the form of a row identifier input text box. If the header is located above the table body, the user can determine the header area range by entering the corresponding row identifier in the text box; the header area correction control can be in the form of a column identifier input text box. If the header is located on the left side of the table body, the user can determine the header area range by entering the corresponding row identifier in the text box; the header area correction control can be in the form of a drag box. Figure 4 This is a schematic diagram of correcting the header area by dragging a selection box in a table adjustment method provided by the present invention. Figure 4As shown, the user can determine the range of the header area by dragging the rectangular box cursor displayed in the target table. Dragging the top or bottom of the rectangular box cursor can add or delete the corresponding row, and dragging the left or right side of the rectangular cursor can add or delete the corresponding column. The header area correction control can be in the form of a slider, and can specifically include two sub-sliders, which correspond to the row where the top and bottom of the header area are located, respectively. The user determines the top and bottom of the header area by dragging the two sub-sliders, thereby determining the range of the header area. The specific form of the header area correction control can be configured according to user needs and is not limited here.

[0094] In this embodiment, various forms of header area correction controls are used to meet the user's differentiated operation needs, and the header area range is conveniently corrected, thereby improving the user experience.

[0095] Based on any of the above embodiments, in one embodiment, generating and displaying an adjusted target table based on the adjusted table header area includes:

[0096] Removing the area of ​​the target table that is not included in the adjusted table header area and the corresponding adjusted table body area to obtain the adjusted target table;

[0097] The adjusted target table is displayed.

[0098] Specifically, the part outside the adjusted header area and body area is an invalid area and will not be used in the process of parsing the table. To avoid interference with the table parsing, the area of ​​the target table that is not included in the adjusted header area and the corresponding adjusted body area can be removed to obtain the adjusted target table and display it through the display device.

[0099] For example, Figure 5 For the existing technology Figure 1 The diagram after adjusting the table in Figure 5 As shown, 51 in the figure is the table header area determined by the prior art, and 52 in the figure is the table body area determined by the prior art. Figure 6 According to the table adjustment method of the present invention Figure 5 The table in the table is corrected and then displayed again, as shown in the following figure: Figure 6 As shown, 61 in the figure is the re-determined header area, and 62 in the figure is the re-determined body area. Areas not included in the adjusted header area and body area, such as the data areas of "MMM Company", "Salary Information Table", and "May", are removed and no longer displayed.

[0100] In this embodiment, by removing the areas of the target table that are not included in the adjusted table header area and table body area, interference of invalid areas on table parsing is avoided.

[0101] Based on any of the above embodiments, in one embodiment, displaying the adjusted target table includes:

[0102] Displaying the header area of ​​the adjusted target table according to the first display mode;

[0103] displaying the adjusted table body area in the target table according to the second display mode;

[0104] The first display mode and the second display mode are different table display modes.

[0105] Specifically, in order to facilitate the user to distinguish the current header area and body area, the header area and the body area can also be distinguished by different display modes, and the header area of ​​the adjusted target table can be displayed according to the first display mode, and the body area of ​​the adjusted target table can be displayed according to the second display mode. For example, the header area can be displayed as a first background color (corresponding to the first display mode), and the body area can be displayed as a second background color (corresponding to the second display mode). It is also possible to display the data (including text, characters, numbers, etc.) in the header area in a first color (corresponding to the first display mode), and the data in the body area in a second color (corresponding to the second display mode).

[0106] In this embodiment, the header area and the body area are distinguished by different display modes, which makes it easier for users to distinguish between the header area and the body area, thereby improving user experience.

[0107] Based on any of the above embodiments, in one embodiment, when the target table is in a displayed state, the data in the target table is in an editable state;

[0108] When the adjusted target table is in a displayed state, the data in the adjusted target table is editable.

[0109] Specifically, the target table or the adjusted target table is in an editable state when in a displayed state. The displayed state means that the table contents are presented to the user through an interactive interface in the user terminal. The editable state means that the user can directly edit and adjust the table online in the interactive interface, avoiding the tedious operations of local editing and re-uploading of the table. In the editable state, the user can edit the displayed target table or the adjusted target table, such as deleting invalid rows / columns, correcting erroneous data in the table, etc.

[0110] In this embodiment, an editable function is provided for the target table or the adjusted target table in the displayed state, so that the user avoids the tedious operations of local editing of the table and re-uploading, thereby improving the efficiency of table adjustment.

[0111] Based on any of the above embodiments, in one embodiment, before displaying the target table and the table header area correction control corresponding to the target table, the method further includes:

[0112] Receive target form;

[0113] Determine the header area and body area of ​​the target table according to the table content in the target table;

[0114] Displaying the header area of ​​the target table according to the third display mode;

[0115] Displaying the table body area of ​​the target table according to the fourth display mode;

[0116] The third display mode and the fourth display mode are different table display modes.

[0117] Specifically, before correcting the target table, the process also includes receiving a target table and preliminarily determining the header and body regions of the target table. The table content stored in the header region has different characteristics from the table content stored in the body region. For example, text is more likely to appear in the header region, while characters and numbers are more likely to appear in the body region. Based on this characteristic, the header and body regions of the target table can be determined by analyzing the table content in the target table and displayed in different ways.

[0118] In this embodiment, the header area and body area of ​​the target table are preliminarily determined according to the content of the target table, and are displayed separately in different display modes, so that the user can make corrections on this basis, thereby improving the efficiency of table adjustment.

[0119] Based on any of the above embodiments, in one embodiment, determining the header area and the body area of ​​the target table according to the table content in the target table includes:

[0120] Traverse the data in the target table in order from top to bottom; when traversing the data of the target type, determine the rows above the row where the data of the target type is located in the target table as the header area, and determine the rows below and including the row where the data of the target type is located in the target table as the body area; or traverse the data in the target table, determine the rows in the target table containing the data of the target type as the body area, and determine the rows above the body area as the header area;

[0121] or,

[0122] Traverse the data in the target table from left to right; when traversing the data of the target type, determine the columns to the left of the column where the data of the target type is located in the target table as the header area, and determine the column where the data of the target type is located in the target table and the columns to the right as the body area; or traverse the data in the target table, determine the columns in the target table that contain the data of the target type as the body area, and determine the columns to the left of the body area as the header area.

[0123] Specifically, the data type in the table body involves fixed types of data. For example, the data in the body of a payslip table is generally serial numbers, specific names, salary figures, etc. In this case, numeric data can be used as the target type for detection of the target table. For another example, the data in the body of a report card is generally serial numbers, specific names, score numbers, and score characters (A, B, C, D... grades), etc. In this case, numeric / character data can be used as the target type for detection of the target table to determine the table body area.

[0124] For the case where the header is above the table body, you can traverse the data in the target table from top to bottom. When traversing the data of the target type, the first row in the target table containing data of the target type is used as the first row of the table body, and some rows above the first row of the table body are determined as the header area, and some rows of the target table body and below are determined as the body area. This method determines the boundary between the header area and the body area by detecting the data of the target type, thereby dividing the header area and the body area. Based on the same idea, you can also traverse the data in the target table, determine the area consisting of some rows in the target table containing data of the target type as the body area, and determine some rows above the body area as the header area. This method determines the body area by traversing the data in the entire target table, and then determines the header area based on the body area.

[0125] In the case where the header is located to the left of the table body, you can traverse the data in the target table from left to right. When traversing the data of the target type, the first column in the target table containing data of the target type is used as the first column of the table body. The columns to the left of the first column of the table body are determined as the header area, and the columns to the right of the first column of the table body in the target table are determined as the body area. This method determines the dividing line between the header area and the body area by detecting the data of the target type, thereby dividing the header area and the body area. Based on the same idea, you can also traverse the data in the target table, determine the area consisting of the columns of the target table containing data of the target type as the body area, and determine the columns to the left of the body area as the header area.

[0126] It can be understood that the above method of determining the header area and the body area is better adapted to common tables (such as part of the rows at the top of the table constituting the header area, and part of the columns on the left side of the table constituting the header area). For special tables that may exist, for example, the header area is located at the bottom of the target table, or the header area is located on the right side of the table, the above method of determining the header area and the body area can be simply modified based on the same idea to obtain a method of determining the header area and the body area suitable for special tables, which will not be repeated here.

[0127] In this embodiment, the header area and the body area of ​​the target table are accurately and preliminarily determined by detecting the data of the target type in the target table.

[0128] Based on any of the above embodiments, in one embodiment, determining the header area and the body area of ​​the target table according to the table content in the target table includes:

[0129] Traversing the data in the target table, determining an area consisting of all rows containing the target keyword in the target table as a header area of ​​the target table, and determining some rows below the header area in the target table as a table body area;

[0130] or,

[0131] The data in the target table is traversed, and an area consisting of all columns containing target keywords in the target table is determined as a header area of ​​the target table, and some columns to the right of the header area in the target table are determined as a table body area.

[0132] Specifically, the data in the table header often involves some keywords. For example, the data in the payroll table header often includes "serial number", "name", "XX month", "payable", "subsidy", "YY insurance", "total", etc. For another example, the data in the report card header often includes "serial number", "name", "ZZ (course)", "score", "total score", etc. To this end, you can set up a target keyword library to detect the data in the target table.

[0133] In the case where the table header is located above the table body, the data in the target table can be traversed. When a target keyword is detected (it is understandable that there may be multiple target keywords), the row where the target keyword is located is used as part of the table header area. After traversing the data in the target table, the area consisting of all rows in the target table containing the target keyword is determined as the table header area of ​​the target table, and the rows below the target table header area in the target table are determined as the table body area.

[0134] For the case where the header is located on the left side of the table body, the data in the target table can be traversed. When the target keyword is detected (it can be understood that the target keyword can include multiple ones), the column where the target keyword is located is taken as part of the header area. After traversing the data in the target table, the area composed of all columns in the target table containing the target keyword is determined as the header area of ​​the target table, and some columns in the target table to the right of the header area of ​​the target table are determined as the body area.

[0135] It can be understood that the above method of determining the header area and the body area is better adapted to common tables (such as part of the rows at the top of the table constituting the header area, and part of the columns on the left side of the table constituting the header area). For special tables that may exist, for example, the header area is located at the bottom of the target table, or the header area is located on the right side of the table, the above method of determining the header area and the body area can be simply modified based on the same idea to obtain a method of determining the header area and the body area suitable for special tables, which will not be repeated here.

[0136] In this embodiment, the header area and the body area of ​​the target table are accurately and preliminarily determined by detecting the target keywords in the target table.

[0137] Based on any of the above embodiments, in one embodiment, receiving a file containing a target table includes:

[0138] The target table is obtained from local storage or received over a network.

[0139] Specifically, the target table may be a file stored in a local memory, and accordingly the target table may be directly uploaded from the local memory. The target table may also be a file stored in a cloud, and accordingly the target table stored in the cloud may be uploaded online for adjustment.

[0140] In this embodiment, the target table is obtained from a local memory or received through a network, thereby flexibly obtaining the target table and improving the efficiency of table adjustment.

[0141] A table adjustment method of the present invention is described below through a preferred embodiment. The table adjustment method includes the following steps:

[0142] 1. Select the document

[0143] Select the target table to upload by choosing an online document or a local document. The table adjustment system will automatically determine the header area and body area based on the cell content in the target table.

[0144] 2. Display adjustment results

[0145] The header area automatically determined by the table adjustment system is displayed in gray. Figure 5 , Figure 5 The middle header area 51 will be displayed with a gray background color (current Figure 5 Gray effects are not reflected in the image).

[0146] After the user uploads the target table, the table parsing system parses the entire table. First, it traverses all the table contents. In scenarios like transcripts and payrolls, the content queried by employees or students often contains numbers. Therefore, when a row containing data is found, it is marked as the first row in the table body.

[0147] After locating the first data row in the table body area, all rows above this data row will be defined as header rows. As part of the header area, the table parsing system will automatically determine the header area and display it in gray.

[0148] There may be situations where the target table has a complex header structure (for example, invalid rows in the header), or the header and table body are similar, resulting in incorrect parsing results. For example, when HR uses a multi-row header as the table structure, but when distributing it to employees to query their salaries, only some of the multi-row header rows are actually used as the header, which means there are invalid rows:

[0149] At this time, the user does not need to modify the table and then re-upload it. He can directly click the "Header Correction" button on the table display interface to directly correct the header on this basis.

[0150] 3. Header calibration

[0151] After clicking the "Header Correction" button, the pop-up window will display all the table data of the target table and two range adjustment sliders (corresponding to the header area correction control mentioned above). The upper range adjustment slider corresponds to the top row of the header area, and the lower range adjustment slider corresponds to the bottom row of the header area. Users can drag the upper and lower sliders to reselect the header they want to use.

[0152] 4. Re-render

[0153] After confirming the table header, click the "Confirm" button, the table parsing system will re-render the user's table and display the re-determined table header in gray. After correcting the table header, redundant table headers (i.e. invalid rows) will no longer appear in subsequent settings and query processes. Figure 5 as well as Figure 6 , Figure 6 Removed Figure 5 The invalid table headers ("MMM Company", "Salary Information Table", "May" part) are corrected to obtain a new table header area 61, and the table header area 61 is displayed with a gray background color.

[0154] This embodiment reduces the workload of users who need to jump out of the page and re-edit the table in the event of misreading or omission of the table header parsing, shortens the path to complete publishing, and reduces operational complexity.

[0155] The table adjustment device provided by the present invention is described below. The table adjustment device described below and the table adjustment method described above can be referenced to each other.

[0156] Figure 7 Schematic diagram of the structure of the table adjustment device provided by the present invention, such as Figure 7 As shown, the device includes:

[0157] A first display module 71 is configured to display a target table and a table header area correction control corresponding to the target table; wherein the target table includes a table header area and a table body area;

[0158] An instruction acquisition module 72 is configured to acquire a correction instruction; wherein the correction instruction is generated based on an operation on the header area correction control, and the correction instruction includes a row identifier or a column identifier for adjusting a range of the header area;

[0159] a table correction module 73 for obtaining an adjusted table header area in response to the correction instruction and according to the row identifier or column identifier included in the correction instruction;

[0160] The second display module 74 is configured to generate and display an adjusted target table based on the adjusted table header area.

[0161] This embodiment displays the target table and the corresponding header area controls, allowing the user to conveniently enter correction instructions for adjusting the header area. The correction instructions adjust the header area range, accurately determining the target table's header area. This invention conveniently and accurately determines the table's header and body areas, avoiding the tedious process of modifying and re-uploading the table, thereby improving the user experience.

[0162] Based on any of the above embodiments, in one embodiment, the apparatus further includes:

[0163] A table sending module is used to send the adjusted target table to a query server so that the query server can parse the adjusted target table and generate multiple data records; wherein the data records correspond to the fields contained in the adjusted table header area; the query server is also used to respond to data query requests with query authority based on the multiple data records and return corresponding data records.

[0164] In this embodiment, the adjusted target table is sent to the query server, which facilitates the query server to accurately and efficiently parse out data records for query users, thereby improving the efficiency and accuracy of reverse query.

[0165] Based on any of the above embodiments, in one embodiment, the table correction module 73 includes:

[0166] A first correction unit is configured to add or delete rows corresponding to the row identifiers based on a range of a header area of ​​the target table to obtain an adjusted header area;

[0167] A second correction unit is configured to add or delete columns corresponding to the column identifiers based on the range of the header area of ​​the target table to obtain an adjusted header area;

[0168] The third correction unit is configured to determine, in the target table, the row corresponding to the row identifier or the column corresponding to the column identifier as an adjusted table header area.

[0169] In this embodiment, the header area is accurately determined based on the row identifier or column identifier used to adjust the range of the header area in the correction instruction, and the table is corrected efficiently.

[0170] Based on any of the above embodiments, in one embodiment, the apparatus further includes: a watch body correction module, configured to determine a portion outside the adjusted watch header area that faces the watch body area before adjustment as the adjusted watch body area.

[0171] In this embodiment, after obtaining the adjusted table header area, the table body area is accurately adjusted accordingly, thereby reducing the parsing error rate of the target table.

[0172] Based on any of the above embodiments, in one embodiment, the header area correction control includes at least one of the following: a check box, a row identifier input text box, a column identifier input text box, a drag box, and a slider.

[0173] In this embodiment, various forms of header area correction controls are used to meet the user's differentiated operation needs, and the header area range is conveniently corrected, thereby improving the user experience.

[0174] Based on any of the above embodiments, in one embodiment, the second display module 74 includes:

[0175] a redundancy removal unit, configured to remove the area of ​​the target table that is not included in the adjusted table header area and the corresponding adjusted table body area, to obtain an adjusted target table;

[0176] The adjustment display unit is used to display the adjusted target table.

[0177] In this embodiment, by removing the areas of the target table that are not included in the adjusted table header area and the corresponding adjusted table body area, interference of invalid areas on table parsing is avoided.

[0178] Based on any of the above embodiments, in one embodiment, the adjusting display unit includes:

[0179] A first display subunit, configured to display the adjusted header area of ​​the target table according to a first display mode;

[0180] A second display subunit, configured to display the adjusted table body area in the target table according to a second display mode;

[0181] The first display mode and the second display mode are different table display modes.

[0182] In this embodiment, the header area and the body area are distinguished by different display modes, which makes it easier for users to distinguish between the header area and the body area, thereby improving user experience.

[0183] Based on any of the above embodiments, in one embodiment, the apparatus further includes:

[0184] A first editing module, configured to provide an editing function for the target table when the target table is in a displayed state;

[0185] The second editing module is configured to provide an editing function for the adjusted target table when the adjusted target table is in a displayed state.

[0186] In this embodiment, an editing function is provided for the target table or the adjusted target table in the displayed state, so that the user avoids the tedious operations of local editing of the table and re-uploading, thereby improving the efficiency of table adjustment.

[0187] Based on any of the above embodiments, in one embodiment, the apparatus further includes:

[0188] A table receiving module, configured to receive the target table;

[0189] A table segmentation module, configured to determine a header area and a body area of ​​the target table according to the table content in the target table;

[0190] a third display module, configured to display a header area of ​​the target table according to a third display mode;

[0191] displaying a table body area of ​​the target table according to a fourth display mode;

[0192] The third display mode and the fourth display mode are different table display modes.

[0193] In this embodiment, the header area and body area of ​​the target table are preliminarily determined according to the content of the target table, and are displayed separately in different display modes, so that the user can make corrections on this basis, thereby improving the efficiency of table adjustment.

[0194] Based on any of the above embodiments, in one embodiment, the table segmentation module includes:

[0195] a first table segmentation unit configured to traverse the data in the target table in a top-to-bottom order; when traversing to data of a target type, determine the rows above the row where the data of the target type is located in the target table as a table header area, and determine the rows below and including the row where the data of the target type is located in the target table as a table body area;

[0196] The second table segmentation unit is used to traverse the data in the target table in order from left to right; when traversing the target type of data, the column to the left of the column where the target type of data is located in the target table is determined as the table header area, and the column where the target type of data is located in the target table and the column to the right of the column are determined as the table body area.

[0197] In this embodiment, the header area and the body area of ​​the target table are accurately and preliminarily determined by detecting the data of the target type in the target table.

[0198] Based on any of the above embodiments, in one embodiment, based on any of the above embodiments, in one embodiment, the table segmentation module includes:

[0199] a third table segmentation unit, configured to traverse the data in the target table, determine an area consisting of all rows in the target table containing the target keyword as a table header area of ​​the target table, and determine a portion of rows in the target table below the table header area as a table body area;

[0200] The fourth table segmentation unit is used to traverse the data in the target table, determine the area consisting of all columns in the target table containing the target keyword as the header area of ​​the target table, and determine some columns to the right of the header area of ​​the target table as the table body area.

[0201] In this embodiment, the header area and the body area of ​​the target table are accurately and preliminarily determined by detecting the target keywords in the target table.

[0202] Based on any of the above embodiments, in one embodiment, the table receiving module is specifically configured to obtain the target table from a local storage, or receive the target table through a network.

[0203] In this embodiment, the target table is obtained from a local memory or received through a network, thereby flexibly obtaining the target table and improving the efficiency of table adjustment.

[0204] Figure 8 An example of a physical structure diagram of an electronic device is shown below. Figure 8 As shown, the electronic device may include: a processor 810, a communication interface 820, a memory 830, and a communication bus 840, wherein the processor 810, the communication interface 820, and the memory 830 communicate with each other via the communication bus 840. The processor 810 may call the logic instructions in the memory 830 to execute all or part of the steps of the table adjustment method provided above, the method comprising: displaying a target table and a header area correction control corresponding to the target table; wherein the target table includes a header area and a table body area; obtaining a correction instruction, wherein the correction instruction is generated based on an operation on the header area correction control, and the correction instruction includes a row identifier or a column identifier for adjusting the range of the header area; in response to the correction instruction, obtaining an adjusted header area according to the row identifier or column identifier included in the correction instruction; and generating and displaying an adjusted target table based on the adjusted header area.

[0205] In addition, the logic instructions in the above-mentioned memory 830 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when sold or used as an independent product. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0206] On the other hand, the present invention also provides a computer program product, which includes a computer program stored on a computer-readable storage medium, and the computer program includes program instructions. When the program instructions are executed by a computer, the computer can execute all or part of the steps of the above-mentioned table adjustment method, the method including: displaying a target table and a header area correction control corresponding to the target table; wherein the target table includes a header area and a table body area; obtaining a correction instruction, wherein the correction instruction is generated based on the operation of the header area correction control, and the correction instruction includes a row identifier or a column identifier for adjusting the range of the header area; in response to the correction instruction, obtaining an adjusted header area according to the row identifier or column identifier included in the correction instruction; generating an adjusted target table based on the adjusted header area and displaying it.

[0207] On the other hand, the present invention also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, is implemented to perform all or part of the steps of the above-mentioned table adjustment method, the method comprising: displaying a target table and a header area correction control corresponding to the target table; wherein the target table comprises a header area and a body area; obtaining a correction instruction, wherein the correction instruction is generated based on an operation on the header area correction control, and the correction instruction includes a row identifier or a column identifier for adjusting the range of the header area; in response to the correction instruction, obtaining an adjusted header area according to the row identifier or column identifier contained in the correction instruction; generating an adjusted target table based on the adjusted header area and displaying it.

[0208] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, i.e., they may be located in one location or distributed across multiple network units. Some or all of the modules may be selected based on actual needs to achieve the objectives of the present embodiment. Persons of ordinary skill in the art will be able to understand and implement the present invention without inventive effort.

[0209] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a necessary general hardware platform, or of course, by hardware. Based on this understanding, the essence of the above technical solution or the part that contributes to the existing technology can be embodied in the form of a software product. The computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a magnetic disk, an optical disk, etc., and includes a number of instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or certain parts of the embodiments.

[0210] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the various embodiments of the present invention.

Claims

1. A table adjustment method, characterized in that: include: Displaying a target table and a header area correction control corresponding to the target table; wherein the target table includes a header area and a table body area; the header area includes an invalid area, and the invalid area contains information that will not be used when the server generates data records; the header area correction control is a control for adjusting the display range of the header area; Obtaining a correction instruction; wherein the correction instruction is generated based on an operation on the header area correction control, and the correction instruction includes a row identifier or a column identifier for adjusting a range of the header area; In response to the correction instruction, obtaining an adjusted header area according to the row identifier or column identifier included in the correction instruction; generating and displaying an adjusted target table based on the adjusted table header area; wherein the adjusted target table does not include the invalid area; the adjusted target table is used by the server to authenticate the querying user after receiving the query request of the querying user, and if the authentication is successful, returning data records corresponding to the querying user based on the attribute information in the adjusted table header area and the data in the table body; The step of obtaining an adjusted header area in response to the correction instruction according to a row identifier or a column identifier included in the correction instruction includes: For the horizontal header, based on the header area range of the target table, the row corresponding to the row identifier is added or deleted to obtain an adjusted header area; Alternatively, for the vertical header, based on the header area range of the target table, the columns corresponding to the column identifiers are added or deleted to obtain an adjusted header area.

2. The table adjustment method according to claim 1, characterized in that: After generating and displaying the adjusted target table based on the adjusted table header area, the method further includes: Sending the adjusted target table to a query server, so that the query server can parse the adjusted target table and generate a plurality of data records; The data records correspond to the fields included in the adjusted header area; the query server is further configured to respond to a data query request with query authority based on the plurality of data records and return corresponding data records.

3. The table adjustment method according to claim 1, wherein: The step of obtaining an adjusted header area in response to the correction instruction according to a row identifier or a column identifier included in the correction instruction further includes: In the target table, the row corresponding to the row identifier or the column corresponding to the column identifier is determined as the adjusted table header area.

4. The table adjustment method according to claim 1, wherein: The step of generating and displaying the adjusted target table based on the adjusted table header area includes: removing the area of ​​the target table that is not included in the adjusted table header area and the corresponding adjusted table body area to obtain an adjusted target table; The adjusted target table is displayed.

5. The table adjustment method according to claim 4, characterized in that: The target table after display adjustment includes: Displaying the header area of ​​the adjusted target table according to the first display mode; displaying the adjusted table body area in the target table according to the second display mode; The first display mode and the second display mode are different table display modes.

6. The table adjustment method according to claim 1, wherein: When the target table is in a displayed state, the data in the target table is in an editable state; When the adjusted target table is in a displayed state, the data in the adjusted target table is in an editable state.

7. The table adjustment method according to any one of claims 1 to 6, characterized in that: Before displaying the target table and the table header area correction control corresponding to the target table, the method further includes: receiving the target form; Determine a header area and a body area of ​​the target table according to the table content in the target table; Displaying a header area of ​​the target table according to a third display mode; displaying a table body area of ​​the target table according to a fourth display mode; The third display mode and the fourth display mode are different table display modes.

8. The table adjustment method according to claim 7, characterized in that: The determining of the header area and the body area of ​​the target table according to the table content in the target table includes: Traversing the data in the target table, determining an area consisting of all rows containing target keywords in the target table as a header area of ​​the target table, and determining some rows below the header area in the target table as a body area; or, The data in the target table is traversed, and an area consisting of all columns containing target keywords in the target table is determined as a header area of ​​the target table, and some columns to the right of the header area in the target table are determined as a table body area.

9. A table adjustment device, characterized in that: include: A first display module is configured to display a target table and a header area correction control corresponding to the target table; wherein the target table includes a header area and a table body area; the header area includes an invalid area, which contains information that will not be used when the server generates data records; and the header area correction control is a control for adjusting the display range of the header area; an instruction acquisition module, configured to acquire a correction instruction, wherein the correction instruction is generated based on an operation on the header area correction control, and the correction instruction includes a row identifier or a column identifier for adjusting a range of the header area; a table correction module, configured to respond to the correction instruction and obtain an adjusted table header area according to a row identifier or a column identifier included in the correction instruction; a second display module, configured to generate and display an adjusted target table based on the adjusted table header area; wherein the adjusted target table does not include the invalid area; the adjusted target table is used by the server to authenticate the querying user after receiving the query request from the querying user, and if the authentication is successful, return a data record corresponding to the querying user based on the attribute information in the adjusted table header area and the data in the table body; The table correction module includes: A first correction unit is configured to add or delete rows corresponding to the row identifiers for the horizontal header, based on the header area range of the target table, to obtain an adjusted header area; The second correction unit is configured to add or delete columns corresponding to the column identifiers for the vertical header based on the header area range of the target table to obtain an adjusted header area.

10. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, all or part of the steps of the table adjustment method according to any one of claims 1 to 8 are implemented.

11. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, all or part of the steps of the table adjustment method according to any one of claims 1 to 8 are implemented.

12. A computer program product comprising computer-executable instructions, characterized in that: When executed, the instruction is used to implement all or part of the steps of the table adjustment method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Table generation method, table generation device, storage medium and electronic equipment

    CN113779943A