CN108197114B - Method and device for detecting table data, storage medium and electronic device - Google Patents

Method and device for detecting table data, storage medium and electronic device Download PDF

Info

Publication number
CN108197114B
CN108197114B CN201810055422.7A CN201810055422A CN108197114B CN 108197114 B CN108197114 B CN 108197114B CN 201810055422 A CN201810055422 A CN 201810055422A CN 108197114 B CN108197114 B CN 108197114B
Authority
CN
China
Prior art keywords
detection
target
detection rule
data
table element
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201810055422.7A
Other languages
Chinese (zh)
Other versions
CN108197114A (en
Inventor
王�琦
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201810055422.7A priority Critical patent/CN108197114B/en
Publication of CN108197114A publication Critical patent/CN108197114A/en
Application granted granted Critical
Publication of CN108197114B publication Critical patent/CN108197114B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/205Parsing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/166Editing, e.g. inserting or deleting
    • G06F40/177Editing, e.g. inserting or deleting of tables; using ruled lines

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • User Interface Of Digital Computer (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a method and a device for detecting table data, a storage medium and an electronic device. Wherein, the method comprises the following steps: the method comprises the steps that a first table element is obtained on a table data detection client, wherein the table data detection client is used for detecting the first table element, and the first table element is to-be-detected; acquiring a target detection rule file corresponding to a first table element identifier carried by a first table element, wherein the table element identifier and the detection rule file with a corresponding relationship are stored in a table data detection client, and the target detection rule file is used for indicating a target detection rule which the target table data carried by the first table element should accord with; detecting whether the target table data accords with a target detection rule or not to obtain a detection result; and displaying the first form element, the target form data and the detection result which have the corresponding relation on the form data detection client. The invention solves the technical problem of low detection efficiency when the form data is detected.

Description

Method and device for detecting table data, storage medium and electronic device
Technical Field
The present invention relates to the field of communications, and in particular, to a method and an apparatus for detecting table data, a storage medium, and an electronic apparatus.
Background
The number of configuration tables of an application program during development and operation can be more and more, and the table content can be greatly increased along with version updating. Format or logic errors are easy to occur when planning and operating personnel of the application edit a large amount of table contents, so that the subsequent flow of testing, modifying and retesting wastes a large amount of time of the planning, operating and testing personnel. Therefore, it is necessary to plan and operate personnel to check the contents of the table. The traditional detection method is to plan and visually detect the table result by operators, or write code programs in table files to detect the table content. Both of these methods have major drawbacks. The scheme of visually inspecting the table results by planning and operators consumes a lot of manpower. Manual detection of a large number of tables is easy to see seriously or miss the table contents, and visual detection only can see whether the format is correct or not and cannot detect the correctness of logic. The scheme of writing a code program in the table file to detect the table content is high in requirement on personnel. Writing a code program requires that planning and operating personnel have certain logical thinking ability and programming foundation, most planning and operating personnel do not have programming ability, and the personnel with programming ability are not clear about the detection rule of the table content, so that the communication cost between the planning and operating personnel and the table content is huge.
In view of the above problems, no effective solution has been proposed.
Disclosure of Invention
The embodiment of the invention provides a method and a device for detecting table data, a storage medium and an electronic device, which are used for at least solving the technical problem of low detection efficiency when the table data is detected.
According to an aspect of an embodiment of the present invention, there is provided a method for detecting table data, including: the method comprises the steps that a first table element is obtained on a table data detection client, wherein the table data detection client is used for detecting the first table element, and the first table element is to-be-detected; acquiring a target detection rule file corresponding to a first table element identifier carried by the first table element, wherein the table element identifier and the detection rule file with a corresponding relationship are stored in the table data detection client, and the target detection rule file is used for indicating a target detection rule which the target table data carried by the first table element should accord with; detecting whether the target table data accords with the target detection rule or not to obtain a detection result; and displaying the first table element, the target table data and the detection result which have corresponding relations on the table data detection client.
According to another aspect of the embodiments of the present invention, there is also provided a table data detection apparatus, including: the system comprises a first acquisition module, a first storage module and a second acquisition module, wherein the first acquisition module is used for acquiring a first table element on a table data detection client, the table data detection client is used for detecting the first table element, and the first table element is a table element to be detected; a second obtaining module, configured to obtain a target detection rule file corresponding to a first table element identifier carried in the first table element, where the table element identifier and the detection rule file having a corresponding relationship are stored in the table data detection client, and the target detection rule file is used to indicate a target detection rule that target table data carried in the first table element should meet; the detection module is used for detecting whether the target table data accords with the target detection rule or not to obtain a detection result; and the display module is used for displaying the first table element, the target table data and the detection result which have the corresponding relation on the table data detection client.
According to another aspect of the embodiments of the present invention, there is also provided a storage medium, characterized in that the storage medium stores therein a computer program, wherein the computer program is configured to execute the method described in any one of the above when executed.
According to another aspect of the embodiments of the present invention, there is also provided an electronic apparatus, including a memory and a processor, wherein the memory stores therein a computer program, and the processor is configured to execute the method described in any one of the above through the computer program.
In the embodiment of the invention, a first table element is obtained on a table data detection client, wherein the table data detection client is used for detecting the first table element, and the first table element is a table element to be detected; acquiring a target detection rule file corresponding to a first table element identifier carried by a first table element, wherein the table element identifier and the detection rule file with a corresponding relationship are stored in a table data detection client, and the target detection rule file is used for indicating a target detection rule which the target table data carried by the first table element should accord with; detecting whether the target table data accords with a target detection rule or not to obtain a detection result; the method comprises the steps of displaying a first table element, target table data and a detection result which have corresponding relations on a table data detection client, obtaining the first table element to be detected on the table data detection client, obtaining a target detection rule file corresponding to the first table element, enabling the table data detection client to automatically determine whether the target table data in the first table element meets a target detection rule in the target detection rule file, and displaying the detection result on the table data detection client.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the invention and together with the description serve to explain the invention without limiting the invention. In the drawings:
FIG. 1 is a diagram illustrating an alternative method for detecting tabular data according to an embodiment of the present invention;
FIG. 2 is a diagram illustrating an application environment of an alternative method for detecting table data according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of an alternative apparatus for detecting tabular data in accordance with embodiments of the present invention;
fig. 4 is a first schematic application scenario of an alternative table data detection method according to an embodiment of the present invention;
fig. 5 is a schematic diagram of an application scenario of an optional table data detection method according to an embodiment of the present invention;
fig. 6 is a schematic view of an application scenario of an alternative table data detection method according to an embodiment of the present invention;
fig. 7 is a schematic diagram of an application scenario of an alternative table data detection method according to an embodiment of the present invention;
fig. 8 is a schematic view of an application scenario of an alternative table data detection method according to an embodiment of the present invention;
Fig. 9 is a schematic diagram six of an application scenario of an alternative table data detection method according to an embodiment of the present invention; and
FIG. 10 is a schematic diagram of an alternative electronic device according to an embodiment of the invention.
Detailed Description
In order to make the technical solutions of the present invention better understood, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are capable of operation in sequences other than those illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
According to an aspect of an embodiment of the present invention, there is provided a method for detecting table data, as shown in fig. 1, the method including:
s102, a first form element is obtained from a form data detection client, wherein the form data detection client is used for detecting the first form element, and the first form element is a form element to be detected;
s104, acquiring a target detection rule file corresponding to a first table element identifier carried by a first table element, wherein the table element identifier and the detection rule file with a corresponding relation are stored in the table data detection client, and the target detection rule file is used for indicating a target detection rule which the target table data carried by the first table element should accord with;
s106, detecting whether the target table data accords with a target detection rule to obtain a detection result;
and S108, displaying the first form element, the target form data and the detection result which have the corresponding relation on the form data detection client.
Alternatively, in this embodiment, the above table data detection method may be applied to a hardware environment formed by the electronic device 202 shown in fig. 2. As shown in fig. 2, a form data detection client 204 is installed in the electronic device 202, and the electronic device 202 is configured to obtain a first form element on the form data detection client, where the form data detection client is configured to detect the first form element, and the first form element is a form element to be detected; acquiring a target detection rule file corresponding to a first table element identifier carried by a first table element, wherein the table element identifier and the detection rule file with a corresponding relationship are stored in a table data detection client, and the target detection rule file is used for indicating a target detection rule which the target table data carried by the first table element should accord with; detecting whether the target table data accords with a target detection rule or not to obtain a detection result; and displaying the first form element, the target form data and the detection result which have the corresponding relation on the form data detection client.
Optionally, in this embodiment, the above table data detection method may be, but is not limited to, applied to a scenario in which table data in a table file in an application is detected. The application program may be, but is not limited to, various types of applications, such as an online education application, an instant messaging application, a community space application, a game application, a shopping application, a browser application, a financial application, a multimedia application, a live application, and the like. Specifically, the method can be applied to, but not limited to, the above scenario of detecting the form data in the form file in the game application program, or can also be applied to, but not limited to, the above scenario of detecting the form data in the form file in the instant messaging application program, so as to improve the detection efficiency. The above is only an example, and this is not limited in this embodiment.
Optionally, in this embodiment, the detection method of the table data may be, but is not limited to, applied to the table data detection client.
Optionally, in this embodiment, the table elements may include, but are not limited to: a table file, a worksheet in a table file, a column in a worksheet, a row in a worksheet, a cell, etc.
Optionally, in this embodiment, the identifier of the first table element carried by the first table element may be an affiliation represented by a name of the table element. For example: the first table element is the third column in worksheet 3 in table file 1, the filename of table file 1 is A, the name of worksheet 3 is BBB, and the name of the third column is CC. The first table element identification may be a-BBB-CC.
Optionally, in this embodiment, the target detection rule carried in the target detection rule file corresponding to the first table element identifier may be obtained by editing by a user, or may be automatically generated according to a requirement on the content or structure of the target table data in the table element.
In an alternative embodiment, the table data detection client obtains the first table element input by the user, and the obtaining may be by inputting the storage path by the user, or may be by displaying a list of table elements on the table data detection client for selection by the user. The table data detection client acquires a target detection rule file corresponding to a first table element identifier carried by a first table element, detects whether target table data accords with a target detection rule or not to obtain a detection result, and displays the first table element, the target table data and the detection result which have corresponding relations.
It can be seen that, through the above steps, a first table element to be detected is obtained on the table data detection client, a target detection rule file corresponding to the first table element is obtained, the table data detection client automatically determines whether the target table data in the first table element meets the target detection rule in the target detection rule file, and then the detection result is displayed on the table data detection client, so that automatic detection and batch detection of the table data are realized, the technical effect of improving the detection efficiency when the table data is detected is realized, and the technical problem of low detection efficiency when the table data is detected is solved.
As an optional scheme, the obtaining of the target detection rule file corresponding to the first table element identifier carried by the first table element includes:
s1, acquiring a second form element on the form data detection client, wherein the second form element is a form element of the detection rule to be edited, and the second form element comprises the first form element;
s2, acquiring a detection rule set corresponding to a second table element, wherein the detection rule set comprises one or more first type detection rules and/or one or more second type detection rules, the first type detection rules are detection rules which the table data in the second table element does not need to meet the conditions, and the second type detection rules are detection rules which the table data in the second table element needs to meet the target conditions;
S3, generating a detection rule file carrying a second table element identifier and a detection rule set, wherein the second table element carries the second table element identifier;
and S4, acquiring the target detection rule file carrying the first table element identifier from the detection rule file.
Optionally, in this embodiment, the table data detection client may obtain the detection rule set corresponding to the second table element through an editing operation performed by a user on the table data detection client, or may also automatically obtain the detection rule set corresponding to the second table element through analyzing the content and structure of data in the second table element.
Optionally, in this embodiment, the detection rule may include, but is not limited to, two types of detection rules, one is a detection rule that the table data in the second table element does not need to be met without a condition, and the other is a detection rule that the table data in the second table element needs to be met when a target condition is met, where the target condition may be set by a user according to a detection requirement.
Optionally, in this embodiment, the detection rule is generated by receiving edit information on the basic detection rule, a user may perform an editing operation on the basic detection rule to form edit information, and send the edit information to the form data detection client, and the form data detection client performs a corresponding editing operation on the corresponding basic detection rule according to the received edit information, so as to obtain a specific detection rule in the detection rule set corresponding to the second form element, and generate the detection rule set.
For example: receiving first editing information and/or second editing information on a table data detection client, wherein the first editing information is used for indicating a first editing operation on a first basic detection rule to obtain one or more first-type detection rules, the second editing information is used for indicating a second editing operation on a second basic detection rule under a target condition to obtain a second-type detection rule corresponding to the target condition, the first basic detection rule and the second basic detection rule are detection rules preset in the table data detection client, the first editing operation is executed on the first basic detection rule in response to the first editing information to generate one or more first-type detection rules, and/or the second editing operation is executed on the second basic detection rule in response to the second editing information to generate one or more second-type detection rules, one or more first type detection rules and/or one or more second type detection rules are determined as the set of detection rules.
Optionally, in this embodiment, the detection rule corresponding to the form element may be obtained through an editing process, and the user may select a second form element that needs to edit the detection rule on the form data detection client, and edit the detection rule corresponding to the second form element in the rule editing interface, for example: adding rules, deleting rules, editing conditions, setting parameters, selecting rule types, setting execution strengths (e.g., strict execution), and the like.
Optionally, in this embodiment, the basic detection rule is a detection rule preset in the table data detection client. Such as: greater than, less than, inclusive, starting with … …, and so forth.
Optionally, in this embodiment, the table data detection client may obtain detection order information indicating an execution order of the detection rules, and carry the detection order information in the detection rule file, so that the detection rules are executed according to the execution order. For example: the table data detection client may obtain detection sequence information, where the detection sequence information is used to indicate an execution sequence of detection rules included in the detection rule set, and determine the detection rule set carrying the second table element identifier and the detection sequence information as a detection rule file.
Alternatively, in this embodiment, the execution order of the detection rules may be automatically generated by the form data detection client according to the detection rules and the predetermined order setting rules, or may be set by the user when editing the detection rules.
Optionally, in this embodiment, the generated detection rule file may be saved as a detection rule template and applied to the detection process of other form elements, so as to simplify the process of obtaining the detection rule and improve the detection efficiency of the form data. For example: after generating the detection rule file carrying the second table element identifier and the detection rule set, the detection rule file may be saved as a detection rule template, and the saved detection rule template may be used to detect the table element matched with the data structure of the table data in the second table element
As an alternative scheme, displaying the first form element, the target form data and the detection result with the corresponding relationship on the form data detection client includes:
s1, allocating a first identifier for the first form element of which the detection result is that the target form data accords with the target detection rule, and allocating a second identifier for the first form element of which the detection result is that the target form data does not accord with the target detection rule;
s2, displaying a first table element having a first identifier on the table data detecting client, and displaying the target table data in the first table element having the first identifier;
s3, displaying the first table element having the second identifier on the table data detecting client, and displaying the target table data in the first table element having the second identifier.
Optionally, in this embodiment, the first identifier and the second identifier may be, but are not limited to, identifiers in the form of different cell colors, different icons, different text colors, and the like, so as to distinguish form data of different detection results.
Optionally, in this embodiment, after table data of different detection results are obtained, the detection results may be displayed, so that a user may quickly and effectively modify the table data with errors. For example: after displaying the first table element with the corresponding relationship, the target table data and the detection result on the table data detection client, the detection result corresponding to the first table element with the first identifier may be displayed in a case where it is detected that the first table element with the first identifier is performed with the first operation, and the detection result corresponding to the first table element with the second identifier may be displayed in a case where it is detected that the first table element with the second identifier is performed with the second operation.
Optionally, in this embodiment, the user may directly modify, on the form data detection client, the form data in which the target form data does not conform to the target detection rule, and automatically save the modification result in the first form element.
As an optional scheme, detecting whether the target table data conforms to the target detection rule, and obtaining the detection result includes:
s1, acquiring the form file where the first form element is located, and searching the worksheet where the first form element is located from the form file;
s2, extracting column data in a target column corresponding to the first table element from the worksheet, and determining the column data as target table data, wherein the column data comprises data carried by one or more cells in the target column;
s3, inputting the data carried by each cell in the data carried by one or more cells into a target detection rule to obtain a detection result corresponding to each cell;
s4, determining that a first cell in which data carried in one or more cells meet a target detection rule corresponds to a first detection result, and a second cell in which data carried in one or more cells do not meet the target detection rule corresponds to a second detection result.
Alternatively, in this embodiment, taking the first table element as an example of a column in the worksheet, the detection process may be, but is not limited to, inputting data in each cell in the column as an input parameter into the target detection rule to determine whether the data conforms to the rule, so as to obtain a detection result of each cell data in the column.
It should be noted that, for simplicity of description, the above-mentioned method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present invention is not limited by the order of acts, as some steps may occur in other orders or concurrently in accordance with the invention. Further, those skilled in the art will appreciate that the embodiments described in this specification are presently preferred and that no acts or modules are required by the invention.
Through the description of the foregoing embodiments, it is clear to those skilled in the art that the method according to the foregoing embodiments may be implemented by software plus a necessary general hardware platform, and certainly may also be implemented by hardware, but the former is a better implementation mode in many cases. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which is stored in a storage medium (e.g., ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.
According to another aspect of the embodiments of the present invention, there is also provided a table data detection apparatus for implementing the above table data detection method, as shown in fig. 3, the apparatus including:
1) a first obtaining module 32, configured to obtain a first table element on a table data detection client, where the table data detection client is configured to detect the first table element, and the first table element is a table element to be detected;
2) a second obtaining module 34, configured to obtain a target detection rule file corresponding to a first table element identifier carried in a first table element, where the table element identifier and the detection rule file having a corresponding relationship are stored in the table data detection client, and the target detection rule file is used to indicate a target detection rule that the target table data carried in the first table element should conform to;
3) the detection module 36 is configured to detect whether the target table data meets a target detection rule, so as to obtain a detection result;
4) and the display module 38 is configured to display the first form element, the target form data and the detection result, which have the corresponding relationship, on the form data detection client.
Alternatively, in this embodiment, the above table data detection apparatus may be applied to a hardware environment formed by the electronic device 202 shown in fig. 2. As shown in fig. 2, a form data detection client 204 is installed in the electronic device 202, and the electronic device 202 is configured to obtain a first form element on the form data detection client, where the form data detection client is configured to detect the first form element, and the first form element is a form element to be detected; acquiring a target detection rule file corresponding to a first table element identifier carried by a first table element, wherein the table element identifier and the detection rule file with a corresponding relationship are stored in a table data detection client, and the target detection rule file is used for indicating a target detection rule which the target table data carried by the first table element should accord with; detecting whether the target table data accords with a target detection rule or not to obtain a detection result; and displaying the first form element, the target form data and the detection result which have the corresponding relation on the form data detection client.
Optionally, in this embodiment, the above table data detection apparatus may be, but is not limited to, applied in a scenario of detecting table data in a table file in an application program. The application program may be, but is not limited to, various types of applications, such as an online education application, an instant messaging application, a community space application, a game application, a shopping application, a browser application, a financial application, a multimedia application, a live application, and the like. Specifically, the method can be applied to, but not limited to, the above scenario of detecting the form data in the form file in the game application program, or can also be applied to, but not limited to, the above scenario of detecting the form data in the form file in the instant messaging application program, so as to improve the detection efficiency. The above is only an example, and this is not limited in this embodiment.
Optionally, in this embodiment, the table data detection apparatus may be, but is not limited to, applied to the table data detection client.
Optionally, in this embodiment, the table elements may include, but are not limited to: a table file, a worksheet in a table file, a column in a worksheet, a row in a worksheet, a cell, etc.
Optionally, in this embodiment, the identifier of the first table element carried by the first table element may be an affiliation represented by a name of the table element. For example: the first table element is the third column in worksheet 3 in table file 1, the filename of table file 1 is A, the name of worksheet 3 is BBB, and the name of the third column is CC. The first table element identification may be a-BBB-CC.
Optionally, in this embodiment, the target detection rule carried in the target detection rule file corresponding to the first table element identifier may be obtained by editing by a user, or may be automatically generated according to a requirement on the content or structure of the target table data in the table element.
In an alternative embodiment, the table data detection client obtains the first table element input by the user, and the obtaining may be by inputting the storage path by the user, or may be by displaying a list of table elements on the table data detection client for selection by the user. The table data detection client acquires a target detection rule file corresponding to a first table element identifier carried by a first table element, detects whether target table data accords with a target detection rule or not to obtain a detection result, and displays the first table element, the target table data and the detection result which have corresponding relations.
It can be seen that, by the above apparatus, a first form element to be detected is obtained on a form data detection client, and a target detection rule file corresponding to the first form element is obtained, and the form data detection client automatically determines whether the target form data in the first form element meets the target detection rule in the target detection rule file, and then displays the detection result on the form data detection client, thereby implementing automatic detection and batch detection of form data, and further implementing a technical effect of improving detection efficiency when detecting form data, and further solving a technical problem of low detection efficiency when detecting form data.
As an optional scheme, the second obtaining module includes:
1) the system comprises a first obtaining unit, a second obtaining unit and a first editing unit, wherein the first obtaining unit is used for obtaining a first table element on a table data detection client;
2) the second obtaining unit is configured to obtain a detection rule set corresponding to a second table element, where the detection rule set includes one or more first-type detection rules and/or one or more second-type detection rules, the first-type detection rule is a detection rule that table data in the second table element does not need to meet an unconditional condition, and the second-type detection rule is a detection rule that table data in the second table element needs to meet a target condition;
3) The generating unit is used for generating a detection rule file carrying a second table element identifier and a detection rule set, wherein the second table element carries the second table element identifier;
4) and the third acquisition unit is used for acquiring the target detection rule file carrying the first table element identifier from the detection rule file.
Optionally, in this embodiment, the table data detection client may obtain the detection rule set corresponding to the second table element through an editing operation performed by a user on the table data detection client, or may also automatically obtain the detection rule set corresponding to the second table element through analyzing the content and structure of data in the second table element.
Optionally, in this embodiment, the detection rule may include, but is not limited to, two types of detection rules, one is a detection rule that the table data in the second table element does not need to be met without a condition, and the other is a detection rule that the table data in the second table element needs to be met when a target condition is met, where the target condition may be set by a user according to a detection requirement.
Optionally, in this embodiment, the detection rule is generated by receiving edit information of the basic detection rule, a user may perform an edit operation on the basic detection rule to form edit information, and send the edit information to the form data detection client, and the form data detection client performs a corresponding edit operation on the corresponding basic detection rule according to the received edit information, so as to obtain a specific detection rule in the detection rule set corresponding to the second form element, and generate the detection rule set.
For example: the second acquisition unit includes: the receiving subunit is configured to receive, on the table data detection client, first editing information and/or second editing information, where the first editing information is used to indicate a first editing operation performed on a first basic detection rule to obtain one or more first type detection rules, the second editing information is used to indicate a second editing operation performed on a second basic detection rule under a target condition to obtain a second type detection rule corresponding to the target condition, and the first basic detection rule and the second basic detection rule are detection rules preset in the table data detection client; an operation subunit, configured to perform a first editing operation on the first basic detection rule in response to the first editing information to generate one or more first type detection rules, and/or perform a second editing operation on the second basic detection rule in response to the second editing information to generate one or more second type detection rules; a first determining subunit, configured to determine one or more first type detection rules and/or one or more second type detection rules as a detection rule set.
Optionally, in this embodiment, the detection rule corresponding to the form element may be obtained through an editing process, and the user may select a second form element that needs to edit the detection rule on the form data detection client, and edit the detection rule corresponding to the second form element in the rule editing interface, for example: adding rules, deleting rules, editing conditions, setting parameters, selecting rule types, setting execution strengths (e.g., strict execution), and the like.
Optionally, in this embodiment, the basic detection rule is a detection rule preset in the table data detection client. Such as: greater than, less than, inclusive, starting with … …, and so forth.
Optionally, in this embodiment, the table data detection client may obtain detection order information indicating an execution order of the detection rules, and carry the detection order information in the detection rule file, so that the detection rules are executed according to the execution order. For example: the generation unit includes: an acquisition subunit configured to acquire detection order information, where the detection order information is used to indicate an execution order of detection rules included in a detection rule set; and the second determining subunit is configured to determine the detection rule set carrying the second table element identifier and the detection sequence information as a detection rule file.
Alternatively, in this embodiment, the execution order of the detection rules may be automatically generated by the form data detection client according to the detection rules and the predetermined order setting rules, or may be set by the user when editing the detection rules.
Optionally, in this embodiment, the generated detection rule file may be saved as a detection rule template and applied to the detection process of other form elements, so as to simplify the process of obtaining the detection rule and improve the detection efficiency of the form data. For example: the above-mentioned device still includes: and the storage module is used for storing the detection rule file as a detection rule template, wherein the detection rule template is used for detecting the table elements matched with the data structure of the table data in the second table elements.
As an alternative, the display module includes:
1) the distribution unit is used for distributing a first identifier for a first table element of which the target table data accords with the target detection rule for the detection result and distributing a second identifier for a first table element of which the target table data does not accord with the target detection rule for the detection result;
2) a first display unit configured to display a first table element having a first identifier on the table data detection client, and display target table data in the first table element having the first identifier;
3) and the second display unit is used for displaying the first table element with the second identifier on the table data detection client and displaying the target table data in the first table element with the second identifier.
Optionally, in this embodiment, the first identifier and the second identifier may be, but are not limited to, identifiers in the form of different cell colors, different icons, different text colors, and the like, so as to distinguish form data of different detection results.
Optionally, in this embodiment, after table data of different detection results are obtained, the detection results may be displayed, so that a user may quickly and effectively modify the table data with errors. For example: the above-mentioned device still includes: a third display unit, configured to display a detection result corresponding to the first table element with the first identifier if it is detected that the first table element with the first identifier is performed with the first operation; and the fourth display unit is used for displaying the detection result corresponding to the first table element with the second identifier under the condition that the second operation is performed on the first table element with the second identifier.
Optionally, in this embodiment, the user may directly modify, on the form data detection client, the form data in which the target form data does not conform to the target detection rule, and automatically save the modification result in the first form element.
As an optional solution, the detection module includes:
1) the fourth obtaining unit is used for obtaining the form file where the first form element is located and searching the working table where the first form element is located from the form file;
2) the extraction unit is used for extracting column data in a target column corresponding to the first table element from the worksheet and determining the column data as target table data, wherein the column data comprises data carried by one or more cells in the target column;
3) the input unit is used for inputting the data carried by each cell in the data carried by one or more cells into the target detection rule to obtain a detection result corresponding to each cell;
4) the determining unit is used for determining that a first cell in which the data carried in the one or more cells meets the target detection rule corresponds to a first detection result, and a second cell in which the data carried in the one or more cells does not meet the target detection rule corresponds to a second detection result.
Alternatively, in this embodiment, taking the first table element as an example of a column in the worksheet, the detection process may be, but is not limited to, inputting the data in each cell in the column as an input parameter into the target detection rule to determine whether the data conforms to the rule, so as to obtain the detection result of each cell data in the column.
The application environment of the embodiment of the present invention may refer to the application environment in the above embodiments, but is not described herein again. The embodiment of the invention provides an optional specific application example of the connection method for implementing the real-time communication.
As an alternative embodiment, the above table data detection method may be applied, but not limited to, in the scenarios of detecting Excel table data as shown in fig. 4 to fig. 8. The following illustrates and describes pertinent terms in this alternative embodiment. It should be noted that, in this alternative embodiment, the detection rule may be simply referred to as a rule. The table is an Excel table as an example, and the table elements are columns in an Excel worksheet as an example.
Source code: a text file written according to a certain programming language specification is a series of human-readable computer language instructions. The code of the original program (e.g., C # code) is compiled to generate a computer program.
xls file format: the file format and the binary file storage mode used before the Excel 2003 edition. The maximum number of rows supported by the xls file is 65536 rows and the maximum number of columns supported is 256 columns.
xlsx file format: the file format used after the Excel 2007 version is essentially a set of xml files stored in a zip compact package. The maximum number of rows supported by the xlsx file is 1048576 rows and the maximum number of columns supported is 16384 columns.
VBA macro: a program scripting language which can be written in Excel completes functions specified by a program.
Basic rules: is the basic rule provided by the scheme itself, such as the basic rule conditions of greater than, less than, equal to, including, etc. based on the cells.
Self-defining a rule expression: the rule set formed by the basic rules freely selected by the user comprises and/or relations, thereby forming the logic expression. The structure of the expressions is similar to that of ((condition one and condition two) or (condition three and condition four)), and the logical relationship between the conditional expressions can be customized by a user.
Self-defining a rule group: the rule expression set is composed of a user-defined rule expression and/or a relation. The logical relationships between the regular expressions in the rule set are consistent.
A user-defined logic conditional branch: the user forms a rule set similar to:
1. if (custom rule set one) then (custom rule set two);
2. otherwise if (custom rule set three) then (custom rule set four);
3. otherwise if (custom rule set five) then (custom rule set six);
9. and finally (custom rule set N).
The above logical relationship may accomplish coverage of multiple conditional branch paths.
Script: an executable file written according to a certain format using a particular programming language may be temporarily called and executed by an application program. The script, when executed, is translated by an interpreter of the program into machine-recognizable instructions and executed in program order.
Program set: an intermediate instruction set containing metadata information is compiled and generated by a certain programming language, and can be dynamically loaded by an application program to generate a corresponding code class.
Rule template: the method is a mode of storing the self-defined rule group or the self-defined logic conditional branch into an independent rule file. The rule template can be applied to the Excel file content with the same or similar content.
In the scene, according to Excel table contents, custom rule editing is carried out on column data required to be detected in a worksheet in each Excel table file, after a detection rule suitable for the table contents is created, the specified worksheet contents are detected, and a detection result is generated.
Optionally, in this embodiment, the user may use the basic rule provided by the client by default to edit the custom rule condition, the custom rule group, and the custom condition branch logic, so as to detect the table content of the specified Excel file. If the basic rule provided by default by the system cannot meet the requirement of the user, the user can carry out secondary development on the basic rule and write a new script to add the new basic rule.
Optionally, in this embodiment, the provided client may automatically load all Excel files in the specified directory, support file formats such as xls and xlsx, and do not need to close the Excel file in the loading process, thereby facilitating the user to perform other operations on the Excel file.
Optionally, in this embodiment, the user may perform the following operation steps on the client to detect the form data by using the client.
The method comprises the following operation steps: as shown in fig. 4, first, the user can select an Excel form file, a work table, and a column name for editing the detection rule in the main interface. The client may automatically list the worksheet files included in the selected form file and the column names in the selected worksheet. For a blank column in the worksheet, the client may identify it as blank. The client may automatically look up the data row in the worksheet whose first row is not empty and mark it as the column name. The user may manually designate other non-empty rows as column names.
And the second operation step: as shown in fig. 5, after the user selects the column that needs to edit the rule, the rule set required for detecting the selected column is given in the rule design interface by adding a common rule or a conditional rule or a combination of the two. The common rule is a regular expression of direct detection without a condition, and the conditional rule is detection of an expression that data satisfies 'if' after a condition. The normal rule will be detected before the conditional rule. The user can adjust the execution sequence of each rule by clicking the up and down buttons or dragging the rule box.
And the third operation step: as shown in fig. 6, the user can add the rule groups and the rules in the rule groups by himself, and each rule group or rule is connected with an and or relationship, so that a regular expression structure similar to ((condition one and condition two) or (condition three and condition four)) can be generated. A single rule consists of basic rules which are larger than, smaller than, inclusive of, unique, and the like. The common rule set is directly applied to the selected column data itself, and the rule set with the conditions is applied to the selected table file, the work table and the column data, so that the definition of rule detection conditions crossing the table can be realized.
And the fourth operation step: as shown in fig. 7, in the rule checking interface, the column to be checked may be selected individually, or all columns included in the entire table file may be selected, or all table files may be selected, and data checking may be performed simultaneously. The user can quickly jump to the rule editing interface to modify the rule through the editing function.
And the operation step five: as shown in fig. 8, the detection result interface displays the entire worksheet data, and gives the number of errors, and highlights the cell data with the errors. The user can click the error cell to check the specific error prompt and quickly jump to the next error cell. The worksheet passing the verification will give a prompt directly in a highlighted manner.
Optionally, in this embodiment, the shared mode file stream may be used to open an Excel file, so as to ensure that the user can perform detection without closing the Excel, and then sequentially traverse each cell content according to the row-column order, and store the cell content as a blank character string if the cell content is empty or does not exist.
Optionally, in this embodiment, in order to facilitate secondary development by the user, a script engine supporting C # format scripts is used for rule detection. Before the client is started each time, the locally owned script is checked, and the newly modified script is compiled again to generate a corresponding program set. And the unmodified script directly loads the corresponding existing program set so as to improve the starting speed of the client.
Optionally, in this embodiment, a user is supported to add, delete, and modify a script in a customized manner, so that the user can expand functions without modifying the source code of the client. The script file written by the user in the secondary development process needs to meet a certain coding specification, and the client can automatically detect the script code and give an error prompt in the writing process of the user.
Alternatively, in this embodiment, as shown in fig. 9, the rules edited by the user may have the following hierarchical organization structure: each workbook rule includes a plurality of worksheet rules, each worksheet rule including a plurality of column rules. Each column rule includes a plurality of rule pairs. The rule pairs without conditions are normal rules and the rule pairs with conditions are conditional rules. All common rules need to be satisfied simultaneously, but the conditional regulations are mutually exclusive, and only one of the rules needs to be satisfied. If all conditional rule relationships are not satisfied, the final conditional rule needs to be satisfied. Each rule pair has two parts of a condition and a rule, wherein the condition part can be empty, which indicates that the current rule is a common rule and has no condition judgment. Both the conditions and the rule portions in each rule pair include multiple rule sets. Each rule group comprises a plurality of rule lists, and each rule list is connected by an and/or relationship, which indicates that the rule lists need to be satisfied simultaneously or independently. Each rule list comprises a plurality of basic rules, and each basic rule is connected by an and-or relation, and the basic rules are required to be simultaneously satisfied or individually satisfied.
Optionally, in this embodiment, a rule template support is provided for columns of the same or similar structure used by a user, so that the user can share the same detection rule among different columns, the user editing time is saved, and the possibility of rule errors is reduced. For rules using rule templates, the column data may no longer be stored inside the column rules, but the template content may be directly referenced, and the template itself is stored separately. This has the advantage that when the template is modified, all the referenced column rules are automatically modified. Meanwhile, the template connection can be selected to be cancelled or disconnected, and after the template connection is cancelled, the contents of the column rules are copied to the independent rules from the interior of the rule template. After the template connection is disconnected, the column rules can be freely edited or restored to the rule templates again. And after editing column rules of the reference rule template, automatically disconnecting the template connection, and storing the rule template contents while storing the editing.
Optionally, in this embodiment, the rule detection of the table data may be performed through the following process:
and finding and loading an Excel file based on the rule file. And finding and loading the Excel file referenced by the rule pair with the condition in the rule. And traversing the detection list and detecting a single Excel worksheet. And traversing the Excel worksheet, obtaining column rules and column data, and detecting a single column. And traversing the common condition rules in the column rules, checking whether the common condition rules are met, and if any common rule is not met, directly reporting an error. And traversing the condition rules in the column rules, finding one of the condition rules which meets the condition, and executing the rule detection under the condition. If no satisfied condition is found, the detection of the final condition rule is performed. The traversal condition detects whether all or any of the rule lists are satisfied according to the and/or relationship for the following rule group list. And traversing the rule list below the rule group, and detecting whether all or any one basic rule is satisfied according to the AND-OR relationship.
And calling a script engine, transmitting the column data to the script, and detecting whether the basic detection rule is met. And outputting all detection results, and formatting the detection results into standard detection results.
In this embodiment, a detection method of Excel form data based on a custom rule is provided. By using the method, the configuration error in the Excel table can be comprehensively and rapidly detected, so that the correction can be carried out. By the method, the testing time brought by the application program configuration and release process can be greatly reduced, the human resources of planning, operating and testing personnel are saved, and the efficiency of the application program release process is improved.
According to still another aspect of the embodiments of the present invention, there is also provided an electronic apparatus for implementing the detection of the above-mentioned table data, as shown in fig. 10, the electronic apparatus including: one or more processors 1002 (only one of which is shown), in which a computer program is stored, a memory 1004, a sensor 1006, an encoder 1008 and a transmission means 1010, the processor being arranged to perform the steps of any of the above-described method embodiments by means of the computer program.
Optionally, in this embodiment, the electronic apparatus may be located in at least one network device of a plurality of network devices of a computer network.
Optionally, in this embodiment, the processor may be configured to execute the following steps by a computer program:
s1, acquiring a first form element on a form data detection client, wherein the form data detection client is used for detecting the first form element, and the first form element is a form element to be detected;
s2, acquiring a target detection rule file corresponding to a first form element identifier carried by a first form element, wherein the form data detection client stores the form element identifier and a detection rule file with a corresponding relationship, and the target detection rule file is used for indicating a target detection rule which the target form data carried by the first form element should accord with;
s3, detecting whether the target table data accords with the target detection rule to obtain a detection result;
and S4, displaying the first form element, the target form data and the detection result which have corresponding relations on the form data detection client.
Alternatively, it can be understood by those skilled in the art that the structure shown in fig. 10 is only an illustration, and the electronic device may also be a terminal device such as a smart phone (e.g., an Android phone, an iOS phone, etc.), a tablet computer, a palm computer, a Mobile Internet Device (MID), a PAD, and the like. Fig. 10 is a diagram illustrating a structure of the electronic device. For example, the electronic device may also include more or fewer components (e.g., network interfaces, display devices, etc.) than shown in FIG. 10, or have a different configuration than shown in FIG. 10.
The memory 1004 may be used to store software programs and modules, such as program instructions/modules corresponding to the method and apparatus for detecting table data in the embodiment of the present invention, and the processor 1002 executes various functional applications and data processing by running the software programs and modules stored in the memory 1004, that is, implementing the control method of the target component described above. The memory 1004 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 1004 may further include memory located remotely from the processor 1002, which may be connected to the terminal through a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The transmission device 1010 is used for receiving or transmitting data via a network. Examples of the network may include a wired network and a wireless network. In one example, the transmission device 1010 includes a Network adapter (NIC) that can be connected to a router via a Network cable and other Network devices so as to communicate with the internet or a local area Network. In one example, the transmission device 1010 is a Radio Frequency (RF) module, which is used for communicating with the internet in a wireless manner.
Among other things, the memory 1004 is used to store application programs.
Embodiments of the present invention also provide a storage medium having a computer program stored therein, wherein the computer program is arranged to perform the steps of any of the above method embodiments when executed.
Alternatively, in the present embodiment, the storage medium may be configured to store a computer program for executing the steps of:
s1, acquiring a first form element on a form data detection client, wherein the form data detection client is used for detecting the first form element, and the first form element is a form element to be detected;
s2, acquiring a target detection rule file corresponding to a first form element identifier carried by a first form element, wherein the form data detection client stores the form element identifier and a detection rule file with a corresponding relationship, and the target detection rule file is used for indicating a target detection rule which the target form data carried by the first form element should accord with;
s3, detecting whether the target table data accords with the target detection rule to obtain a detection result;
and S4, displaying the first form element, the target form data and the detection result which have corresponding relations on the form data detection client.
Optionally, the storage medium is further configured to store a computer program for executing the steps included in the method in the foregoing embodiment, which is not described in detail in this embodiment.
Alternatively, in this embodiment, a person skilled in the art may understand that all or part of the steps in the methods of the foregoing embodiments may be implemented by a program instructing hardware associated with the terminal device, where the program may be stored in a computer-readable storage medium, and the storage medium may include: flash disks, Read-Only memories (ROMs), Random Access Memories (RAMs), magnetic or optical disks, and the like.
The above-mentioned serial numbers of the embodiments of the present invention are only for description, and do not represent the advantages and disadvantages of the embodiments.
The integrated unit in the above embodiments, if implemented in the form of a software functional unit and sold or used as a separate product, may be stored in the above computer-readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for causing one or more computer devices (which may be personal computers, servers, network devices, etc.) to execute all or part of the steps of the method according to the embodiments of the present invention.
In the above embodiments of the present invention, the description of each embodiment has its own emphasis, and reference may be made to the related description of other embodiments for parts that are not described in detail in a certain embodiment.
In the several embodiments provided in the present application, it should be understood that the disclosed client may be implemented in other ways. The above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units is only one type of division of logical functions, and there may be other divisions when actually implemented, for example, a plurality of units or components may be combined or may be integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, units or modules, and may be in an electrical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit may be implemented in the form of hardware, or may also be implemented in the form of a software functional unit.
The foregoing is only a preferred embodiment of the present invention, and it should be noted that, for those skilled in the art, various modifications and decorations can be made without departing from the principle of the present invention, and these modifications and decorations should also be regarded as the protection scope of the present invention.

Claims (9)

1. A method for detecting tabular data, comprising:
acquiring a first table element carrying a first table element identifier and a second table element carrying a second table element identifier on a table data detection client;
the table data detection client is used for detecting the first table element, the first table element is a table element to be detected in a table file, the second table element is a table element of a detection rule to be edited, and the second table element comprises the first table element;
Acquiring a detection rule set which carries detection sequence information and corresponds to the second table element, wherein the detection rule set comprises a first type detection rule and a second type detection rule, the first type detection rule is a detection rule which is required by table data in the second table element and is not required to be met by conditions, the second type detection rule is a detection rule which is required by the table data in the second table element and is met by conditions meeting target conditions, and the detection sequence information is used for indicating an execution sequence of the detection rules in the detection rule set;
generating a detection rule file carrying the second table element identifier and the detection rule set, and storing the detection rule file as a detection rule template, wherein the detection rule template is used for detecting the table elements matched with the data structure of the table data in the second table elements;
acquiring a target detection rule file carrying the first table element identifier from the detection rule file, wherein the target detection rule file is used for indicating a target detection rule which is required to be met by target table data carried in the first table element;
Detecting the target table data based on the target detection rule to obtain a detection result;
when the detection result represents that the target table data accords with the target detection rule, allocating a first identifier to the first table element;
displaying a first table element with the first identifier on the table data detection client, and displaying the target table data in the first table element with the first identifier;
when the detection result represents that the target table data does not accord with the target detection rule, distributing a second identifier for the first table element;
displaying the first table element with the second identifier on the table data detection client, and displaying the target table data in the first table element with the second identifier;
wherein a display style of the first logo is different from a display style of the second logo.
2. The method according to claim 1, wherein the obtaining of the detection rule set carrying detection order information corresponding to the second table element includes:
receiving first editing information and/or second editing information on the table data detection client, wherein the first editing information is used for indicating a first editing operation performed on a first basic detection rule to obtain the first type detection rule, the second editing information is used for indicating a second editing operation performed on a second basic detection rule under the target condition to obtain a second type detection rule corresponding to the target condition, and the first basic detection rule and the second basic detection rule are detection rules preset in the table data detection client;
Executing the first editing operation on the first basic detection rule in response to the first editing information to generate the first type detection rule, and/or executing the second editing operation on the second basic detection rule in response to the second editing information to generate the second type detection rule;
determining the first type of detection rule, and/or the second type of detection rule as the set of detection rules.
3. The method of claim 1, wherein the generating a detection rule file carrying the second table element identifier and the detection rule set comprises:
and determining the detection rule set carrying the second table element identifier and the detection sequence information as the detection rule file.
4. The method of claim 1, further comprising:
in the case that the first table element with the first identifier is detected to be executed with a first operation, displaying a detection result corresponding to the first table element with the first identifier;
and in the case of detecting that the first table element with the second identifier is executed with a second operation, displaying a detection result corresponding to the first table element with the second identifier.
5. The method according to claim 1, wherein the detecting the target table data based on the target detection rule to obtain the detection result comprises:
acquiring a table file where the first table element is located, and searching a working table where the first table element is located from the table file;
extracting column data in a target column corresponding to the first table element from the worksheet, and determining the column data as the target table data, wherein the column data comprises data carried by one or more cells in the target column;
inputting the data carried by each cell in the data carried by the one or more cells into the target detection rule to obtain the detection result corresponding to each cell;
and determining that a first cell in which the data carried in the one or more cells meet the target detection rule corresponds to a first detection result, and a second cell in which the data carried in the one or more cells do not meet the target detection rule corresponds to a second detection result.
6. An apparatus for detecting table data, comprising:
The table data detection system comprises a first acquisition module, a second acquisition module and a third acquisition module, wherein the first acquisition module is used for acquiring a first table element carrying a first table element identifier on a table data detection client;
the table data detection client is used for detecting the first table element, and the first table element is a table element to be detected in a table file;
a second obtaining module, configured to obtain a target detection rule file corresponding to a first table element identifier carried in the first table element, where the target detection rule file is used to indicate a target detection rule that target table data carried in the first table element should meet;
the second acquisition module includes:
a first obtaining unit, configured to obtain, on a table data detection client, a second table element carrying a second table element identifier, where the second table element is a table element of a detection rule to be edited, and the second table element includes the first table element;
a second obtaining unit, configured to obtain a detection rule set that carries detection order information and corresponds to the second table element, where the detection rule set includes a first type detection rule and a second type detection rule, the first type detection rule is a detection rule that table data in the second table element does not need to meet an unconditional condition, the second type detection rule is a detection rule that table data in the second table element needs to meet a target condition when the table data in the second table element meets the target condition, and the detection order information is used to indicate an execution order of the detection rules in the detection rule set;
A generating unit, configured to generate a detection rule file carrying the second table element identifier and the detection rule set;
a third obtaining unit, configured to obtain the target detection rule file carrying the first table element identifier from the detection rule file;
the storage module is used for storing the detection rule file as a detection rule template, wherein the detection rule template is used for detecting the table elements matched with the data structure of the table data in the second table elements;
the detection module is used for detecting the target table data based on the target detection rule to obtain a detection result;
the display module is used for distributing a first identifier to the first table element when the detection result represents that the target table data accords with the target detection rule; displaying a first table element with the first identifier on the table data detection client, and displaying the target table data in the first table element with the first identifier; when the detection result represents that the target table data does not accord with the target detection rule, distributing a second identifier for the first table element; displaying the first table element with the second identifier on the table data detection client, and displaying the target table data in the first table element with the second identifier; wherein a display style of the first logo is different from a display style of the second logo.
7. The apparatus of claim 6, wherein the detection module comprises:
a fourth obtaining unit, configured to obtain a table file where the first table element is located, and search a working table where the first table element is located from the table file;
an extracting unit, configured to extract, from the worksheet, column data in a target column corresponding to the first table element, and determine the column data as the target table data, where the column data includes data carried by one or more cells in the target column;
the input unit is used for inputting the data carried by each cell in the data carried by the one or more cells into the target detection rule to obtain the detection result corresponding to each cell;
and the determining unit is used for determining a first detection result corresponding to a first cell in which the data carried in the one or more cells accords with the target detection rule, and a second detection result corresponding to a second cell in which the data carried in the one or more cells does not accord with the target detection rule.
8. A storage medium, in which a computer program is stored, wherein the computer program is arranged to perform the method of any of claims 1 to 5 when executed.
9. An electronic device comprising a memory and a processor, characterized in that the memory has stored therein a computer program, the processor being arranged to execute the method of any of claims 1 to 5 by means of the computer program.
CN201810055422.7A 2018-01-19 2018-01-19 Method and device for detecting table data, storage medium and electronic device Active CN108197114B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810055422.7A CN108197114B (en) 2018-01-19 2018-01-19 Method and device for detecting table data, storage medium and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810055422.7A CN108197114B (en) 2018-01-19 2018-01-19 Method and device for detecting table data, storage medium and electronic device

Publications (2)

Publication Number Publication Date
CN108197114A CN108197114A (en) 2018-06-22
CN108197114B true CN108197114B (en) 2022-07-29

Family

ID=62590383

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810055422.7A Active CN108197114B (en) 2018-01-19 2018-01-19 Method and device for detecting table data, storage medium and electronic device

Country Status (1)

Country Link
CN (1) CN108197114B (en)

Families Citing this family (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109408506B (en) * 2018-09-05 2020-12-11 天津字节跳动科技有限公司 Table data processing method and device
CN109446493B (en) * 2018-10-17 2022-06-24 网易(杭州)网络有限公司 Data processing method, data processing apparatus, storage medium, and electronic apparatus
CN109543160B (en) * 2018-11-23 2023-08-25 网易(杭州)网络有限公司 Checking method, checking device, storage medium and processor for numerical value table
CN109981729B (en) * 2019-02-14 2022-04-05 视联动力信息技术股份有限公司 File processing method and device, electronic equipment and computer readable storage medium
CN110008446A (en) * 2019-02-27 2019-07-12 深圳点猫科技有限公司 The method and electronic equipment that a kind of language based on programming converts form document
CN110413598A (en) * 2019-06-17 2019-11-05 平安科技(深圳)有限公司 List data amending method, device, electronic equipment and storage medium
CN110472209B (en) * 2019-07-04 2024-02-06 深圳同奈信息科技有限公司 Deep learning-based table generation method and device and computer equipment
CN111773728B (en) * 2020-07-09 2024-06-21 网易(杭州)网络有限公司 Data table testing method, device, equipment and storage medium
CN112231337A (en) * 2020-10-20 2021-01-15 中国建设银行股份有限公司 SAS statement detection device and method, electronic device and storage medium
CN112765946B (en) * 2020-12-31 2024-05-14 维沃移动通信有限公司 Chart display method and device and electronic equipment
CN112650762B (en) * 2021-03-15 2021-07-02 腾讯科技(深圳)有限公司 Data quality monitoring method and device, electronic equipment and storage medium
CN113191128B (en) * 2021-05-24 2024-03-19 中国工商银行股份有限公司 Report checking tool generation method and device and electronic equipment
CN114185463B (en) * 2021-11-17 2023-10-13 北京字跳网络技术有限公司 Form processing method, form processing device, electronic equipment and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007183916A (en) * 2005-10-19 2007-07-19 Ntt Docomo Inc Method and apparatus for automatic form input on mobile devices
CN102467561A (en) * 2010-11-19 2012-05-23 金蝶软件(中国)有限公司 Form data filtering method and device
CN104239162A (en) * 2014-09-09 2014-12-24 北京国双科技有限公司 Data check method and data check device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007183916A (en) * 2005-10-19 2007-07-19 Ntt Docomo Inc Method and apparatus for automatic form input on mobile devices
CN102467561A (en) * 2010-11-19 2012-05-23 金蝶软件(中国)有限公司 Form data filtering method and device
CN104239162A (en) * 2014-09-09 2014-12-24 北京国双科技有限公司 Data check method and data check device

Also Published As

Publication number Publication date
CN108197114A (en) 2018-06-22

Similar Documents

Publication Publication Date Title
CN108197114B (en) Method and device for detecting table data, storage medium and electronic device
CN109857667B (en) Interface automation test method, test device, test equipment and storage medium
CN107992458B (en) Table rule generation method and device, storage medium and electronic equipment
CN104899016B (en) Allocating stack Relation acquisition method and device
CN109513211B (en) Art resource file processing method and device and game resource display system
CN109408764B (en) Page area dividing method, device, computing equipment and medium
CN107797826B (en) Rule configuration method based on rule engine, terminal and equipment
CN108293081A (en) Pass through the program playback deep linking of user interface event to mobile application state
CN110221968A (en) Method for testing software and Related product
CN110955428A (en) Page display method and device, electronic equipment and medium
CN109308254B (en) Test method, test device and test equipment
CN108388515A (en) Test data generating method, device, equipment and computer readable storage medium
CN104615463B (en) A kind of system property setting method and terminal
CN104035873A (en) Method and device for generating testing codes
CN105955888A (en) Page debugging and previewing method and system
CN104391786A (en) Webpage automatic test system and method thereof
CN111324535B (en) Control abnormity detection method and device and computer equipment
CN107451112B (en) Form tool data checking method, device, terminal equipment and storage medium
CN108399072A (en) Five application page update method and device
CN105117205A (en) Web page editing method and web page editing device
CN111667231B (en) Automatic tax return method, device, system, computer equipment and storage medium
CN117875288A (en) Form page generation method and device and electronic equipment
CN112274913B (en) Method and device for merging game servers, storage medium and electronic device
CN112463596B (en) Test case data processing method, device and equipment and processing equipment
CN109542501A (en) Browser table compatibility method, device, computer equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant