CN113076358A - Report generation method, device, equipment and storage medium - Google Patents
Report generation method, device, equipment and storage medium Download PDFInfo
- Publication number
- CN113076358A CN113076358A CN202110320377.5A CN202110320377A CN113076358A CN 113076358 A CN113076358 A CN 113076358A CN 202110320377 A CN202110320377 A CN 202110320377A CN 113076358 A CN113076358 A CN 113076358A
- Authority
- CN
- China
- Prior art keywords
- target
- index
- target index
- report
- data
- 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.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 41
- 230000003993 interaction Effects 0.000 claims abstract description 57
- 238000012544 monitoring process Methods 0.000 claims abstract description 49
- 238000005192 partition Methods 0.000 claims description 62
- 238000004364 calculation method Methods 0.000 claims description 48
- 238000013507 mapping Methods 0.000 claims description 18
- 238000001914 filtration Methods 0.000 claims description 11
- 238000004590 computer program Methods 0.000 claims description 10
- 238000001514 detection method Methods 0.000 claims description 9
- 230000003287 optical effect Effects 0.000 description 6
- 238000010586 diagram Methods 0.000 description 5
- 230000002159 abnormal effect Effects 0.000 description 4
- 230000006870 function Effects 0.000 description 4
- 230000008569 process Effects 0.000 description 4
- 230000000007 visual effect Effects 0.000 description 3
- 230000009286 beneficial effect Effects 0.000 description 2
- 239000013307 optical fiber Substances 0.000 description 2
- 230000002093 peripheral effect Effects 0.000 description 2
- 238000012545 processing Methods 0.000 description 2
- 230000000644 propagated effect Effects 0.000 description 2
- 238000003491 array Methods 0.000 description 1
- 238000013473 artificial intelligence Methods 0.000 description 1
- 238000004891 communication Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 238000007667 floating Methods 0.000 description 1
- 230000008707 rearrangement Effects 0.000 description 1
- 238000011160 research Methods 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/24—Querying
- G06F16/248—Presentation of query results
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/24—Querying
- G06F16/245—Query processing
- G06F16/2457—Query processing with adaptation to user needs
Abstract
The embodiment of the invention discloses a report generation method, a report generation device, report generation equipment and a storage medium. The method comprises the following steps: acquiring a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index and a target report type corresponding to the target index; acquiring data corresponding to the target index from a database according to the configuration information corresponding to the target index; calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information; when the index value corresponding to the target index is detected not to be in the monitoring threshold interval corresponding to the target index, generating alarm information corresponding to the target index, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface. The embodiment of the invention can flexibly provide report data for the user according to the service requirement of the user and provide effective report service.
Description
Technical Field
The embodiment of the invention relates to the technical field of computers, in particular to a report generation method, a report generation device, report generation equipment and a storage medium.
Background
The information is displayed in a data report form, which is beneficial to business management and control of enterprises. The current report forms are displayed by developing fixed pages, and each page displays a category of report forms according to a single index and a single dimension. With the increasing application scenes of big data, the increasing data volume and the increasing complexity of the index application scenes, the report service with fixed indexes is difficult to flexibly provide report data for users according to business requirements, and effective service can not be provided any more.
Disclosure of Invention
Embodiments of the present invention provide a report generation method, apparatus, device, and storage medium, which can flexibly provide report data for a user according to business requirements, and provide an effective report service.
In a first aspect, an embodiment of the present invention provides a report generating method, including:
acquiring a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index and a target report type corresponding to the target index;
acquiring data corresponding to the target index from a database according to the configuration information corresponding to the target index;
calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information;
detecting whether the index value corresponding to the target index is in the monitoring threshold interval corresponding to the target index;
when the index value corresponding to the target index is not detected to be in the monitoring threshold interval corresponding to the target index, generating alarm information corresponding to the target index, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface.
In a second aspect, an embodiment of the present invention further provides a report generating apparatus, including:
the index selection module is used for acquiring a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index and a target report type corresponding to the target index;
the data acquisition module is used for acquiring data corresponding to the target index from a database according to the configuration information corresponding to the target index;
the index calculation module is used for calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information;
the index detection module is used for detecting whether the index value corresponding to the target index is in the monitoring threshold interval corresponding to the target index;
and the interface display module is used for generating alarm information corresponding to the target index when detecting that the index value corresponding to the target index is not in the monitoring threshold interval corresponding to the target index, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface.
In a third aspect, an embodiment of the present invention further provides a computer device, including a memory, a processor, and a computer program stored on the memory and executable on the processor, where the processor executes the computer program to implement the report generating method according to the embodiment of the present invention.
In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, where the computer program is executed by a processor to implement the report generating method according to the embodiment of the present invention.
According to the technical scheme of the embodiment of the invention, a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index and a target report type corresponding to the target index are obtained; then acquiring data corresponding to the target index from a database according to configuration information corresponding to the target index, and calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information; then detecting whether the index value corresponding to the target index is in the monitoring threshold interval corresponding to the target index; when the index value corresponding to the target index is not detected to be in the monitoring threshold value interval corresponding to the target index, generating alarm information corresponding to the target index, generating a report of the target index according to the target report type and the index value corresponding to the target index, displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface, acquiring data corresponding to the index selected by the user based on business requirements from massive data stored in a database according to configuration information corresponding to the index selected by the user based on business requirements, calculating the index value of the index in real time, generating the report of the index according to the report type selected by the user based on business requirements, performing visual display on the index value corresponding to the target index according to the report type selected by the user based on business requirements, and detecting whether the index value of the index selected by the user is in a normal fluctuation range, and the abnormal detection result of the index value is visually displayed, so that report data can be flexibly provided for the user according to the business requirements of the user, and effective report service is provided.
Drawings
Fig. 1 is a flowchart of a report generation method according to an embodiment of the present invention.
Fig. 2 is a flowchart of a report generating method according to a second embodiment of the present invention.
Fig. 3 is a schematic structural diagram of a report generating apparatus according to a third embodiment of the present invention.
Fig. 4 is a schematic structural diagram of a computer device according to a fourth embodiment of the present invention.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the invention and are not limiting of the invention.
It should be further noted that, for the convenience of description, only some but not all of the relevant aspects of the present invention are shown in the drawings. Before discussing exemplary embodiments in more detail, it should be noted that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although a flowchart may describe the operations (or steps) as a sequential process, many of the operations can be performed in parallel, concurrently or simultaneously. In addition, the order of the operations may be re-arranged. The process may be terminated when its operations are completed, but may have additional steps not included in the figure. The processes may correspond to methods, functions, procedures, subroutines, and the like.
The inventor aims at the problems that in the related technology, with the increasing application scenes of large data, the data size is larger and the application scenes of indexes are more and more complex, the report service with fixed indexes is difficult to flexibly provide report data for users according to business requirements, and the index value and the detection index value of the indexes are difficult to calculate in real time from mass data and are in a normal fluctuation range, so that effective service can not be provided any more.
Based on the above thought, the inventor creatively proposes: acquiring a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index and a target report type corresponding to the target index; acquiring data corresponding to the target index from a database according to the configuration information corresponding to the target index; calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information; detecting whether the index value corresponding to the target index is in the monitoring threshold interval corresponding to the target index; when the index value corresponding to the target index is not detected to be in the monitoring threshold interval corresponding to the target index, generating alarm information corresponding to the target index, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface.
The benefits of this are: the data corresponding to the index selected by the user based on the service requirement can be obtained from the mass data stored in the database according to the configuration information corresponding to the index selected by the user based on the service requirement, index values of the indexes can be calculated in real time from the mass data, reports of the indexes are generated according to report types selected by users based on business requirements, visually displaying the index value corresponding to the target index according to the report type selected by the user based on the business requirement, can detect whether the index value of the index selected by the user is in the normal fluctuation range or not in real time from the mass data, and visually display the abnormal detection result of the index value, therefore, report data are flexibly provided for users according to the service requirements of the users, the index values of the indexes are calculated in real time from the mass data, whether the index values are in a normal fluctuation range is detected, and effective report service is provided.
Example one
Fig. 1 is a flowchart of a report generation method according to an embodiment of the present invention. The embodiment of the invention is applicable to the condition of generating the report, and the method can be executed by the report generating device provided by the embodiment of the invention, and the device can be realized in a software and/or hardware mode and can be generally integrated in computer equipment. For example in a server. As shown in fig. 1, the method of the embodiment of the present invention specifically includes:
Optionally, the target index is one or more indexes of the report which are selected by the user according to the business requirement and need to be generated. The index is data that measures things, such as registration success rate. The metrics include multiple dimensions, such as a time dimension, an item dimension, and so on. The target dimension corresponding to the target index is one or more dimensions selected by the user for the target index according to the service requirement. The target report type corresponding to the target index is a report type selected by the user for the target index according to the business requirement. The report type is a style indicating that the report is generated. Report types include, but are not limited to: fishbone map, chart (Echart chart), Geographic Information System (GIS) map, table.
Optionally, the obtaining of the target index selected by the user based on the human-computer interaction interface, the target dimension corresponding to the target index, and the target report type corresponding to the target index includes: when a human-computer interaction interface detects a report generation instruction of a user, displaying a plurality of preset selectable indexes through the human-computer interaction interface; acquiring selectable indexes selected by the user as target indexes; displaying a plurality of selectable dimensions corresponding to the selectable indicators selected by the user through the human-computer interaction interface; acquiring selectable dimensions selected by the user as target dimensions corresponding to the target indexes; displaying a plurality of selectable report types corresponding to selectable indexes selected by the user through the human-computer interaction interface; and acquiring the selectable report type selected by the user as a target report type corresponding to the target index.
Optionally, a report generation control is arranged on the human-computer interaction interface. The user can input the report generation instruction by clicking the report generation control.
Optionally, when the human-computer interaction interface detects a report generation instruction of a user, an index selection drop-down box containing a plurality of selectable indexes is provided for the user through the human-computer interaction interface, so that the user selects one or more selectable indexes through the index selection drop-down box as target indexes. One or more selectable indexes selected by a user are obtained as target indexes. The selectable index is an index set in advance according to the service requirement. And setting a plurality of selectable indexes in advance according to the service requirements of each service scene.
Optionally, after one or more selectable indexes selected by the user are obtained and used as target indexes, a dimension selection drop-down box including a plurality of selectable dimensions corresponding to the target indexes selected by the user is provided for the user through the human-computer interaction interface, so that the user can select one or more selectable dimensions through the dimension selection drop-down box and use the selected dimensions as target dimensions corresponding to the target indexes. And acquiring one or more selectable dimensions selected by a user as target dimensions corresponding to the target indexes. The selectable dimension is a dimension which is set for the corresponding selectable index in advance according to the service requirement. And setting a plurality of selectable dimensions for each selectable index in advance according to the service requirements of each service scene.
Optionally, after one or more selectable dimensions selected by the user are obtained and used as target dimensions corresponding to the target indexes, a report type selection drop-down box containing a plurality of selectable report types corresponding to the selectable indexes selected by the user is provided for the user through the human-computer interaction interface, so that the user selects one selectable report type through the report type selection drop-down box and uses the selected selectable report type as the target report type corresponding to the target indexes. And setting a plurality of selectable report types for each selectable index in advance according to the service requirements of each service scene. The selectable report type may be a fishbone map, an Echart map, a GIS map, or a table.
And 102, acquiring data corresponding to the target index from a database according to the configuration information corresponding to the target index.
Optionally, the configuration information corresponding to the target index includes: the data source identification corresponding to the target index, the partition field corresponding to the target index, the data field having a mapping relation with the target index, the calculation mode of the target index and the monitoring threshold interval corresponding to the target index.
Optionally, configuration information corresponding to each index is preset.
Optionally, the database comprises a plurality of data sources. The data source identification is identification information of the data source. Each data source has a corresponding data source identification. The data source identification corresponding to the target index is identification information of a data source where the data corresponding to the target index is located.
Optionally, each data source is partitioned in advance to obtain a plurality of data source partitions. Each data source partition contains a portion of the data in the data source. And setting a corresponding partition field for each data source partition of the data source. The partition field is used to distinguish different data source partitions. And the partition field corresponding to the target index is the partition field of the data source partition where the data corresponding to the target index is located.
Optionally, a plurality of data fields are preset in the database, and each data field represents a data type. When the data items are stored in the database, the data fields of the data items are determined, and the data are stored in the storage positions corresponding to the data fields. Determining data required by index calculation in advance according to the calculation mode of each index, acquiring the data field to which the data belongs, and establishing a mapping relation between the index and the data field to which the data belongs.
Optionally, the calculation mode of each index is preset. The calculation mode of the index can be a calculation function of the index.
Optionally, the monitoring threshold interval corresponding to the target index is a normal fluctuation range of the index value of the target index. And setting a monitoring threshold interval of each index in advance according to the service requirement and the characteristics of each index.
Optionally, the obtaining, according to the configuration information corresponding to the target index, data corresponding to the target index from a database includes: determining a data source corresponding to the target index in a database according to the data source identification corresponding to the target index; determining a data source partition corresponding to the target index in a data source corresponding to the target index according to the partition field corresponding to the target index; and extracting data corresponding to the target index from a data source partition corresponding to the target index according to the data field having a mapping relation with the target index.
Optionally, in each data source in the database, a data source whose data source identifier is consistent with the data source identifier corresponding to the target index is obtained as the data source corresponding to the target index. And then acquiring a data source partition with partition fields consistent with the partition fields corresponding to the target indexes from each data source partition in the data source corresponding to the target indexes, wherein the data source partition is used as the data source partition corresponding to the target indexes. And finally, in each data field in the data source partition corresponding to the target index, determining a data field having a mapping relation with the target index, and extracting data stored in a storage position corresponding to the data field having the mapping relation with the target index as data corresponding to the target index.
Therefore, the data corresponding to each index is stored in a segmented mode according to the data source, the data source partition and the data field in advance, the query range is conveniently reduced when the data corresponding to the index is obtained, full-table scanning is avoided, the data can be rapidly located according to the data source identification, the partition field and the data field, and the data obtaining speed is improved.
Optionally, before extracting, according to a data field having a mapping relationship with the target indicator, data corresponding to the target indicator in a data source partition corresponding to the target indicator, the method further includes: and according to the data filtering condition corresponding to the target index, performing data filtering on the data in the data source partition corresponding to the target index.
Optionally, the data filtering condition is a preset filtering field, a white list or a filtering rule, and is used for filtering data irrelevant to the target index in the data source partition corresponding to the target index, so that customized filtering and other operations can be conveniently performed.
And 103, calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information.
Optionally, the calculating an index value corresponding to the target index according to the data, the target dimension, and the configuration information includes: determining a calculation mode of the target index under the target dimension in the calculation mode of the target index; and calculating the data according to the calculation mode of the target index in the target dimension to obtain an index value corresponding to the target index.
Optionally, the calculation mode of the index in each dimension is preset. The calculation mode of the target index comprises a calculation mode of the target index under each dimension. And determining the calculation mode of the target index under the target dimension in the calculation mode of the target index. And calculating data corresponding to the target index according to the calculation mode of the target index in the target dimension to obtain an index value corresponding to the target index.
Optionally, the monitoring threshold interval corresponding to the target index is a normal fluctuation range of the index value of the target index. And setting a monitoring threshold interval of each index in advance according to the service requirement and the characteristics of each index.
Optionally, the monitoring threshold interval is composed of an upper limit value of the index value of the target index and a lower limit value of the index value of the target index. And when the condition that the index value corresponding to the target index is larger than the upper limit value of the index value of the target index or the index value corresponding to the target index is smaller than the lower limit value of the index value of the target index is detected, determining that the index value corresponding to the target index is not in the monitoring threshold interval corresponding to the target index. And when the condition that the index value corresponding to the target index is smaller than or equal to the upper limit value of the index value of the target index and the index value corresponding to the target index is larger than or equal to the lower limit value of the index value of the target index is detected, determining that the index value corresponding to the target index is in the monitoring threshold interval corresponding to the target index.
Optionally, the setting of the monitoring threshold interval of each index according to the service requirement and the characteristics of each index in advance includes: and setting a monitoring threshold interval of each index according to the data rule floating range of each index.
Optionally, the setting of the monitoring threshold interval of each index according to the service requirement and the characteristics of each index in advance includes: and setting a monitoring threshold interval of each index according to the expert value of each index.
Optionally, the setting of the monitoring threshold interval of each index according to the service requirement and the characteristics of each index in advance includes: and (3) according to an Artificial Intelligence (AI) research and judgment threshold value of each index, setting a monitoring threshold value interval of each index.
And 105, generating alarm information corresponding to the target index, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface.
Optionally, it is detected that the index value corresponding to the target index is not in the monitoring threshold interval corresponding to the target index, which indicates that the index value corresponding to the target index is not in the normal fluctuation range. And the alarm information corresponding to the target index is used for prompting the user that the index value corresponding to the target index is not in the normal fluctuation range.
When the index value corresponding to the target index is not detected to be in the monitoring threshold value interval corresponding to the target index, generating alarm information corresponding to the target index, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface. And displaying the index value corresponding to the target index of the report displayed on the human-computer interaction interface according to the report type selected by the user. The user can browse the index values in the report and determine that the index value corresponding to the target index is not in the normal fluctuation range according to the alarm information displayed on the man-machine interaction interface.
And 106, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the report of the target index on a human-computer interaction interface.
Optionally, the index value corresponding to the target index is detected in the monitoring threshold interval corresponding to the target index, which indicates that the index value corresponding to the target index is in the normal fluctuation range.
When the index value corresponding to the target index is detected to be in the monitoring threshold interval corresponding to the target index, generating a report of the target index directly according to the type of the target report and the index value corresponding to the target index, and displaying the report of the target index on a human-computer interaction interface. And displaying the index value corresponding to the target index of the report displayed on the human-computer interaction interface according to the report type selected by the user. The user can browse the index values in the report.
The embodiment of the invention provides a report generation method, which comprises the steps of obtaining a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index and a target report type corresponding to the target index; then acquiring data corresponding to the target index from a database according to configuration information corresponding to the target index, and calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information; then detecting whether the index value corresponding to the target index is in the monitoring threshold interval corresponding to the target index; when the index value corresponding to the target index is not detected to be in the monitoring threshold value interval corresponding to the target index, generating alarm information corresponding to the target index, generating a report of the target index according to the target report type and the index value corresponding to the target index, displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface, acquiring data corresponding to the index selected by the user based on business requirements from massive data stored in a database according to configuration information corresponding to the index selected by the user based on business requirements, calculating the index value of the index in real time, generating the report of the index according to the report type selected by the user based on business requirements, performing visual display on the index value corresponding to the target index according to the report type selected by the user based on business requirements, and detecting whether the index value of the index selected by the user is in a normal fluctuation range, and the abnormal detection result of the index value is visually displayed, so that report data can be flexibly provided for the user according to the business requirements of the user, and effective report service is provided.
Example two
Fig. 2 is a flowchart of a report generating method according to a second embodiment of the present invention. The embodiment of the present invention may be combined with each optional solution in one or more of the above embodiments, and in the embodiment of the present invention, the configuration information corresponding to the target index includes: the data source identification corresponding to the target index, the partition field corresponding to the target index, the data field having a mapping relation with the target index, the calculation mode of the target index and the monitoring threshold interval corresponding to the target index.
And acquiring data corresponding to the target index from a database according to the configuration information corresponding to the target index, wherein the acquiring comprises: determining a data source corresponding to the target index in a database according to the data source identification corresponding to the target index; determining a data source partition corresponding to the target index in a data source corresponding to the target index according to the partition field corresponding to the target index; and extracting data corresponding to the target index from a data source partition corresponding to the target index according to the data field having a mapping relation with the target index.
And calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information, wherein the calculation comprises: determining a calculation mode of the target index under the target dimension in the calculation mode of the target index; and calculating the data according to the calculation mode of the target index in the target dimension to obtain an index value corresponding to the target index.
As shown in fig. 2, the method of the embodiment of the present invention specifically includes:
Optionally, the database comprises a plurality of data sources. The data source identification is identification information of the data source. Each data source has a corresponding data source identification. The data source identification corresponding to the target index is identification information of a data source where the data corresponding to the target index is located.
Optionally, in each data source in the database, a data source whose data source identifier is consistent with the data source identifier corresponding to the target index is obtained as the data source corresponding to the target index.
Optionally, each data source is partitioned in advance to obtain a plurality of data source partitions. Each data source partition contains a portion of the data in the data source. And setting a corresponding partition field for each data source partition of the data source. The partition field is used to distinguish different data source partitions. And the partition field corresponding to the target index is the partition field of the data source partition where the data corresponding to the target index is located.
Optionally, in each data source partition in the data source corresponding to the target index, a data source partition whose partition field is consistent with the partition field corresponding to the target index is obtained as the data source partition corresponding to the target index.
And 204, extracting data corresponding to the target index from the data source partition corresponding to the target index according to the data field having the mapping relation with the target index.
Optionally, a plurality of data fields are preset in the database, and each data field represents a data type. When the data items are stored in the database, the data fields of the data items are determined, and the data are stored in the storage positions corresponding to the data fields. Determining data required by index calculation in advance according to the calculation mode of each index, acquiring the data field to which the data belongs, and establishing a mapping relation between the index and the data field to which the data belongs.
Optionally, in each data field in the data source partition corresponding to the target indicator, a data field having a mapping relationship with the target indicator is determined, and data stored in a storage location corresponding to the data field having a mapping relationship with the target indicator is extracted as data corresponding to the target indicator.
Optionally, the calculation mode of the index in each dimension is preset. The calculation mode of the target index comprises a calculation mode of the target index under each dimension. And determining the calculation mode of the target index under the target dimension in the calculation mode of the target index.
And step 206, calculating the data according to the calculation mode of the target index in the target dimension to obtain an index value corresponding to the target index.
And calculating data corresponding to the target index according to the calculation mode of the target index in the target dimension to obtain an index value corresponding to the target index.
And 208, generating alarm information corresponding to the target index, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface.
And 209, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the report of the target index on a human-computer interaction interface.
The embodiment of the invention provides a report generation method, which comprises the steps of determining a data source corresponding to a target index in a database according to a data source identifier corresponding to the target index; determining a data source partition corresponding to the target index in the data source corresponding to the target index according to the partition field corresponding to the target index; according to the data fields having mapping relation with the target indexes, extracting data corresponding to the target indexes from the data source partitions corresponding to the target indexes, quickly positioning the data corresponding to the target indexes in the massive data stored in the database according to the data source identification, the partition fields and the data fields in the configuration information corresponding to the indexes selected by a user based on business requirements, improving the data acquisition speed, and determining the calculation mode of the target indexes under the target dimension in the calculation mode of the target indexes; and calculating the data according to the calculation mode of the target index in the target dimension to obtain the index value corresponding to the target index, and calculating the index value of the index selected by the user based on the service requirement in real time.
EXAMPLE III
Fig. 3 is a schematic structural diagram of a report generating apparatus according to a third embodiment of the present invention. As shown in fig. 3, the apparatus includes: the system comprises an index selection module 301, a data acquisition module 302, an index calculation module 303, an index detection module 304 and an interface display module 305.
The index selection module 301 is configured to obtain a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index, and a target report type corresponding to the target index; a data obtaining module 302, configured to obtain, according to the configuration information corresponding to the target index, data corresponding to the target index from a database; an index calculation module 303, configured to calculate an index value corresponding to the target index according to the data, the target dimension, and the configuration information; an index detection module 304, configured to detect whether an index value corresponding to the target index is in a monitoring threshold interval corresponding to the target index; the interface display module 305 is configured to generate alarm information corresponding to the target index when it is detected that the index value corresponding to the target index is not within the monitoring threshold interval corresponding to the target index, generate a report of the target index according to the type of the target report and the index value corresponding to the target index, and display the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface.
The embodiment of the invention provides a report generation device, which is characterized in that a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index and a target report type corresponding to the target index are obtained; then acquiring data corresponding to the target index from a database according to configuration information corresponding to the target index, and calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information; then detecting whether the index value corresponding to the target index is in the monitoring threshold interval corresponding to the target index; when the index value corresponding to the target index is not detected to be in the monitoring threshold value interval corresponding to the target index, generating alarm information corresponding to the target index, generating a report of the target index according to the target report type and the index value corresponding to the target index, displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface, acquiring data corresponding to the index selected by the user based on business requirements from massive data stored in a database according to configuration information corresponding to the index selected by the user based on business requirements, calculating the index value of the index in real time, generating the report of the index according to the report type selected by the user based on business requirements, performing visual display on the index value corresponding to the target index according to the report type selected by the user based on business requirements, and detecting whether the index value of the index selected by the user is in a normal fluctuation range, and the abnormal detection result of the index value is visually displayed, so that report data can be flexibly provided for the user according to the business requirements of the user, and effective report service is provided.
In an optional implementation manner of the embodiment of the present invention, optionally, the report generating apparatus further includes: and the report display module is used for generating a report of the target index according to the type of the target report and the index value corresponding to the target index when the index value corresponding to the target index is detected to be in the monitoring threshold interval corresponding to the target index, and displaying the report of the target index on a human-computer interaction interface.
In an optional implementation manner of the embodiment of the present invention, optionally, the index selection module 301, after obtaining a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index, and a target report type corresponding to the target index, is specifically configured to: when a human-computer interaction interface detects a report generation instruction of a user, displaying a plurality of preset selectable indexes through the human-computer interaction interface; acquiring selectable indexes selected by the user as target indexes; displaying a plurality of selectable dimensions corresponding to the selectable indicators selected by the user through the human-computer interaction interface; acquiring selectable dimensions selected by the user as target dimensions corresponding to the target indexes; displaying a plurality of selectable report types corresponding to selectable indexes selected by the user through the human-computer interaction interface; and acquiring the selectable report type selected by the user as a target report type corresponding to the target index.
In an optional implementation manner of the embodiment of the present invention, optionally, the configuration information corresponding to the target index includes: the data source identification corresponding to the target index, the partition field corresponding to the target index, the data field having a mapping relation with the target index, the calculation mode of the target index and the monitoring threshold interval corresponding to the target index.
In an optional implementation manner of the embodiment of the present invention, optionally, when the data obtaining module 302 obtains the data corresponding to the target index from the database according to the configuration information corresponding to the target index, specifically, the data obtaining module is configured to: determining a data source corresponding to the target index in a database according to the data source identification corresponding to the target index; determining a data source partition corresponding to the target index in a data source corresponding to the target index according to the partition field corresponding to the target index; and extracting data corresponding to the target index from a data source partition corresponding to the target index according to the data field having a mapping relation with the target index.
In an optional implementation manner of the embodiment of the present invention, optionally, the data obtaining module 302 is further configured to: and according to the data filtering condition corresponding to the target index, performing data filtering on the data in the data source partition corresponding to the target index.
In an optional implementation manner of the embodiment of the present invention, optionally, when the index calculation module 303 calculates an index value corresponding to the target index according to the data, the target dimension, and the configuration information, specifically, the index calculation module is configured to: determining a calculation mode of the target index under the target dimension in the calculation mode of the target index; and calculating the data according to the calculation mode of the target index in the target dimension to obtain an index value corresponding to the target index.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
The report generation device can execute the report generation method provided by any embodiment of the invention, and has the corresponding functional modules and beneficial effects of executing the report generation method.
Example four
Fig. 4 is a schematic structural diagram of a computer device according to a fourth embodiment of the present invention. FIG. 4 illustrates a block diagram of an exemplary computer device 12 suitable for use in implementing embodiments of the present invention. The computer device 12 shown in FIG. 4 is only one example and should not bring any limitations to the functionality or scope of use of embodiments of the present invention.
As shown in FIG. 4, computer device 12 is in the form of a general purpose computing device. The components of computer device 12 may include, but are not limited to: one or more processors 16, a memory 28, and a bus 18 that connects the various system components (including the memory 28 and the processors 16).
Computer device 12 typically includes a variety of computer system readable media. Such media may be any available media that is accessible by computer device 12 and includes both volatile and nonvolatile media, removable and non-removable media.
The memory 28 may include computer system readable media in the form of volatile memory, such as Random Access Memory (RAM)30 and/or cache memory 32. Computer device 12 may further include other removable/non-removable, volatile/nonvolatile computer system storage media. By way of example only, storage system 34 may be used to read from and write to non-removable, nonvolatile magnetic media (not shown in FIG. 4, and commonly referred to as a "hard drive"). Although not shown in FIG. 4, a magnetic disk drive for reading from and writing to a removable, nonvolatile magnetic disk (e.g., a "floppy disk") and an optical disk drive for reading from or writing to a removable, nonvolatile optical disk (e.g., a CD-ROM, DVD-ROM, or other optical media) may be provided. In these cases, each drive may be connected to bus 18 by one or more data media interfaces. Memory 28 may include at least one program product having a set (e.g., at least one) of program modules that are configured to carry out the functions of embodiments of the invention.
A program/utility 40 having a set (at least one) of program modules 42 may be stored, for example, in memory 28, such program modules 42 including, but not limited to, an operating system, one or more application programs, other program modules, and program data, each of which examples or some combination thereof may comprise an implementation of a network environment. Program modules 42 generally carry out the functions and/or methodologies of the described embodiments of the invention.
Computer device 12 may also communicate with one or more external devices 14 (e.g., keyboard, pointing device, display 24, etc.), with one or more devices that enable a user to interact with computer device 12, and/or with any devices (e.g., network card, modem, etc.) that enable computer device 12 to communicate with one or more other computing devices. Such communication may be through an input/output (I/O) interface 22. Also, computer device 12 may communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network such as the Internet) via network adapter 20. As shown, network adapter 20 communicates with the other modules of computer device 12 via bus 18. It should be appreciated that although not shown in FIG. 4, other hardware and/or software modules may be used in conjunction with computer device 12, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, among others.
The processor 16 executes various functional applications and data processing by running the program stored in the memory 28, so as to implement the report generating method provided by the embodiment of the present invention: acquiring a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index and a target report type corresponding to the target index; acquiring data corresponding to the target index from a database according to the configuration information corresponding to the target index; calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information; detecting whether the index value corresponding to the target index is in the monitoring threshold interval corresponding to the target index; when the index value corresponding to the target index is not detected to be in the monitoring threshold interval corresponding to the target index, generating alarm information corresponding to the target index, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface.
EXAMPLE five
Fifth, an embodiment of the present invention provides a computer-readable storage medium, where a computer program is stored, and when the computer program is executed by a processor, the method for generating a report according to the fifth embodiment of the present invention is implemented: acquiring a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index and a target report type corresponding to the target index; acquiring data corresponding to the target index from a database according to the configuration information corresponding to the target index; calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information; detecting whether the index value corresponding to the target index is in the monitoring threshold interval corresponding to the target index; when the index value corresponding to the target index is not detected to be in the monitoring threshold interval corresponding to the target index, generating alarm information corresponding to the target index, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface.
Any combination of one or more computer-readable media may be employed. The computer readable medium may be a computer readable signal medium or a computer readable storage medium. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the computer readable storage medium would include the following: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this document, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
A computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Computer program code for carrying out operations for aspects of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or computer device. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
It is to be noted that the foregoing is only illustrative of the preferred embodiments of the present invention and the technical principles employed. It will be understood by those skilled in the art that the present invention is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the invention. Therefore, although the present invention has been described in greater detail by the above embodiments, the present invention is not limited to the above embodiments, and may include other equivalent embodiments without departing from the spirit of the present invention, and the scope of the present invention is determined by the scope of the appended claims.
Claims (10)
1. A report generation method is characterized by comprising the following steps:
acquiring a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index and a target report type corresponding to the target index;
acquiring data corresponding to the target index from a database according to the configuration information corresponding to the target index;
calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information;
detecting whether the index value corresponding to the target index is in the monitoring threshold interval corresponding to the target index;
when the index value corresponding to the target index is not detected to be in the monitoring threshold interval corresponding to the target index, generating alarm information corresponding to the target index, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface.
2. The method according to claim 1, further comprising, after detecting whether the index value corresponding to the target index is within the monitoring threshold interval corresponding to the target index, the following steps:
and when the index value corresponding to the target index is detected to be in the monitoring threshold interval corresponding to the target index, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the report of the target index on a human-computer interaction interface.
3. The method of claim 1, wherein the obtaining of the target index selected by the user based on the human-computer interaction interface, the target dimension corresponding to the target index, and the target report type corresponding to the target index comprises:
when a human-computer interaction interface detects a report generation instruction of a user, displaying a plurality of preset selectable indexes through the human-computer interaction interface;
acquiring selectable indexes selected by the user as target indexes;
displaying a plurality of selectable dimensions corresponding to the selectable indicators selected by the user through the human-computer interaction interface;
acquiring selectable dimensions selected by the user as target dimensions corresponding to the target indexes;
displaying a plurality of selectable report types corresponding to selectable indexes selected by the user through the human-computer interaction interface;
and acquiring the selectable report type selected by the user as a target report type corresponding to the target index.
4. The method of claim 1, wherein the configuration information corresponding to the target metric comprises: the data source identification corresponding to the target index, the partition field corresponding to the target index, the data field having a mapping relation with the target index, the calculation mode of the target index and the monitoring threshold interval corresponding to the target index.
5. The method according to claim 4, wherein the obtaining data corresponding to the target index from a database according to the configuration information corresponding to the target index comprises:
determining a data source corresponding to the target index in a database according to the data source identification corresponding to the target index;
determining a data source partition corresponding to the target index in a data source corresponding to the target index according to the partition field corresponding to the target index;
and extracting data corresponding to the target index from a data source partition corresponding to the target index according to the data field having a mapping relation with the target index.
6. The method of claim 5, further comprising, before extracting data corresponding to the target metric in the data source partition corresponding to the target metric according to the data field having a mapping relationship with the target metric:
and according to the data filtering condition corresponding to the target index, performing data filtering on the data in the data source partition corresponding to the target index.
7. The method of claim 4, wherein the calculating an index value corresponding to the target index according to the data, the target dimension, and the configuration information comprises:
determining a calculation mode of the target index under the target dimension in the calculation mode of the target index;
and calculating the data according to the calculation mode of the target index in the target dimension to obtain an index value corresponding to the target index.
8. A report generation apparatus, comprising:
the index selection module is used for acquiring a target index selected by a user based on a human-computer interaction interface, a target dimension corresponding to the target index and a target report type corresponding to the target index;
the data acquisition module is used for acquiring data corresponding to the target index from a database according to the configuration information corresponding to the target index;
the index calculation module is used for calculating an index value corresponding to the target index according to the data, the target dimension and the configuration information;
the index detection module is used for detecting whether the index value corresponding to the target index is in the monitoring threshold interval corresponding to the target index;
and the interface display module is used for generating alarm information corresponding to the target index when detecting that the index value corresponding to the target index is not in the monitoring threshold interval corresponding to the target index, generating a report of the target index according to the type of the target report and the index value corresponding to the target index, and displaying the alarm information corresponding to the target index and the report of the target index on a human-computer interaction interface.
9. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the report generating method according to any of claims 1-7 when executing the computer program.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the report generating method according to any one of claims 1-7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110320377.5A CN113076358A (en) | 2021-03-25 | 2021-03-25 | Report generation method, device, equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110320377.5A CN113076358A (en) | 2021-03-25 | 2021-03-25 | Report generation method, device, equipment and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN113076358A true CN113076358A (en) | 2021-07-06 |
Family
ID=76611577
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110320377.5A Pending CN113076358A (en) | 2021-03-25 | 2021-03-25 | Report generation method, device, equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113076358A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113642300A (en) * | 2021-07-30 | 2021-11-12 | 南京星云数字技术有限公司 | Report generation method and device, electronic equipment and computer readable medium |
CN114116826A (en) * | 2022-01-26 | 2022-03-01 | 树根互联股份有限公司 | Index calculation system for working condition of Internet of things equipment |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102740247A (en) * | 2011-04-15 | 2012-10-17 | 中国移动通信集团山东有限公司 | Method and device for generating warning message |
CN109657214A (en) * | 2018-09-27 | 2019-04-19 | 深圳壹账通智能科技有限公司 | Report form generation method, device, terminal and storage medium |
CN110688541A (en) * | 2019-10-08 | 2020-01-14 | 中国建设银行股份有限公司 | Report data query method and device, storage medium and electronic equipment |
CN111784176A (en) * | 2020-07-10 | 2020-10-16 | 中国建设银行股份有限公司 | Data processing method, device, server and medium |
-
2021
- 2021-03-25 CN CN202110320377.5A patent/CN113076358A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102740247A (en) * | 2011-04-15 | 2012-10-17 | 中国移动通信集团山东有限公司 | Method and device for generating warning message |
CN109657214A (en) * | 2018-09-27 | 2019-04-19 | 深圳壹账通智能科技有限公司 | Report form generation method, device, terminal and storage medium |
CN110688541A (en) * | 2019-10-08 | 2020-01-14 | 中国建设银行股份有限公司 | Report data query method and device, storage medium and electronic equipment |
CN111784176A (en) * | 2020-07-10 | 2020-10-16 | 中国建设银行股份有限公司 | Data processing method, device, server and medium |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113642300A (en) * | 2021-07-30 | 2021-11-12 | 南京星云数字技术有限公司 | Report generation method and device, electronic equipment and computer readable medium |
CN114116826A (en) * | 2022-01-26 | 2022-03-01 | 树根互联股份有限公司 | Index calculation system for working condition of Internet of things equipment |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110750654A (en) | Knowledge graph acquisition method, device, equipment and medium | |
CN110502519B (en) | Data aggregation method, device, equipment and storage medium | |
CN111709527A (en) | Operation and maintenance knowledge map library establishing method, device, equipment and storage medium | |
CN109710709A (en) | Interest point data processing method, device, electronic equipment and storage medium | |
CN113076358A (en) | Report generation method, device, equipment and storage medium | |
JP2023527100A (en) | Event detection method, device, electronic device, readable storage medium, and computer program | |
US9619364B2 (en) | Grouping and analysis of data access hazard reports | |
CN115391322A (en) | Data checking method, device, equipment, storage medium and program product | |
CN109582906B (en) | Method, device, equipment and storage medium for determining data reliability | |
CN107368568A (en) | A kind of method, apparatus, equipment and storage medium for taking down notes generation | |
CN113779269A (en) | Power grid load data display method and device, electronic equipment and storage medium | |
CN111639173B (en) | Epidemic situation data processing method, device, equipment and storage medium | |
CN115794980A (en) | Data display method, equipment, device and medium | |
CN114201729A (en) | Method, device and equipment for selecting matrix operation mode and storage medium | |
CN111427874B (en) | Quality control method and device for medical data production and electronic equipment | |
CN114265914A (en) | Robot display method, device, equipment and storage medium | |
CN114564354A (en) | Database performance monitoring method and device, electronic equipment and storage medium | |
CN112346678B (en) | Method, device, equipment and storage medium for displaying article information | |
CN107872874B (en) | Method for updating positioning data, server and computer readable medium | |
CN112000559A (en) | Abnormal equipment detection method and device | |
CN111124862A (en) | Intelligent equipment performance testing method and device and intelligent equipment | |
CN115238805B (en) | Training method of abnormal data recognition model and related equipment | |
CN110990445B (en) | Data processing method, device, equipment and medium | |
CN111680116B (en) | Map-based position information display method, system, medium and electronic equipment | |
CN110516024B (en) | Map search result display method, device, 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 |