How to implement the self-service report function in the application

The demand for self-service reporting has become more and more common. In the application software of various industries, whether it is active or passive, they are thinking and trying to realize the self-service reporting function.

In this way, users can analyze and understand data freely and flexibly, and no longer stick to fixed-format data reports. It is convenient, flexible, and has a better experience. At the same time, it can also revitalize the value of more data.

For application software manufacturers, it can save a lot of development and maintenance costs, and at the same time broaden their business scope and enhance their competitiveness

How to do it

This function is usually available in the BI system, but not in the application system. When using it, you have to switch back and forth between the two systems, which is very inconvenient. It is more convenient to use it in the application system.

Find a self-service reporting component that can be integrated

It's quite difficult to do it all by yourself, and the workload is very large. So, the first step is to find a ready-made component

But this step is actually quite difficult. There are many products with self-service reporting functions on the market, but they are basically the complete BI platform solutions mentioned above. It is very difficult to integrate one system platform into another application system. It is not smooth, and these platforms do not take self-service reports as a middleware and separate them out for users to integrate, so it is very difficult

It is easy to be integrated and provides products in the form of middleware. At present, it seems to be running dry reports.

Get method:

1 Download the installation package and install it: http://www.raqsoft.com.cn/download/download-jsbb

2 Download the open source dependency files and replace:

http://c.raqsoft.com.cn/article/1619664848326

The self-service report module of Rungan is open source, and it can be used for free after replacing this file in the ordinary installation package.

integration process

Let's take the easy-to-integrate moisturizing report as an example to see the integration process

Most of the current data informatization projects are in java. The self-service report of Rungan is a standard j2ee application. It only needs to put the jar package, xml and tag description files under the application, and there is no difficulty.

imagepng

Step 1: Copy the jar package

imagepng

Copy the self-service report jar package and related files to the corresponding directory of your application

If there are other requirements, such as exporting EXCEL, etc., you can copy the required packages. For specific operations, you can refer to the documentation.

Step 2: Apply Configuration

1 Copy the contents of the dry web.xml into the web.xml file of the application and merge them in the required order

2 Configure information such as data sources to be analyzed in raqsoftConfig.xml

Step 3: Prepare the dataset

Prepare a data set to be used for self-service reports. We use a SQL sentence from the following order table as the data set

select * from order

imagepng

Step 4: Publish Self-Service Reports

Configure this dataset with tag tags in jsp and publish the jsp to the server

imagepng

Then you can access it through the url and perform self-service operations

imagepng

imagepng

It's that simple, add the tag tag to the jsp, and the self-service report function will be integrated into your own application.

For a more complete and detailed integration process, please refer to:

How to Integrate Self-Service Reporting in Your Application

In addition, the Run Dry Self-Service Report can not only be integrated, but also open source . After integration, the page can be further transformed, so that the page and functions can better adapt to their own system.

Functional Roaming

After the basic functions are integrated, let's take a look at what the self-service report can achieve.

report style

Regular list, grouping, intersecting and other styles are the basic functions of all components

imagepng

imagepng

imagepng

For those with higher complexity, such as the following multi-layer grouping and crossover, there is no problem with the production of stronger capabilities.

imagepng

These reports can also be exported and printed, with complete functions

Various types of statistical graphs can also be generated using ready-made templates

imagepng

imagepng

imagepng

Calculate ability

Look at the style in the big picture, and look at the calculation in the details. Behind the same style, the calculations involved may be very different, some only need to do simple statistical summary, some need to do complex ranking, proportion, year-on-year ratio, etc.

Tools have different self-help capabilities, some are easy to make, some are cumbersome, and some may not be able to do it

ranking

imagepng

proportion

imagepng

year-on-year

imagepng

imagepng

accumulation

imagepng

Filter by complex conditions

imagepng

Data Sources

The role of self-service reports is to analyze data, to turn all kinds of abstract data into concrete and easy-to-understand charts. After the application system integrates self-service reports, it is natural to hope that it can process various types of data and deal with various scenarios. This requires tools that can support various data sources. A temporary file data can be analyzed, and a table can be made with only one sentence of SQL. It is no problem to encounter complex multi-database table associations, which is convenient for multiple reuse semantics. There are also layer tools. If you want to control permissions, you can also control permissions. You can handle various scenarios with ease.

File data source analysis

The data source is EXCEL file, data.xls

imagepng

Configure this EXCEL through the tag tag in jsp, and then publish the page

imagepng

After the release, business personnel can see the data in EXCEL, and can make reports on it

imagepng

SQL data source analysis

The example used in the "Integration Process" chapter uses the data source from SQL, which will not be repeated here. If necessary, you can turn to the above and have a look.

semantic layer

It is more convenient to do ad hoc, simple analysis directly based on SQL. Repeated, frequent analysis If you write SQL every time, you have to use as Chinese name, join, and adding indicators will be troublesome.

Solving these problems through the semantic layer will be much better

Define the semantic layer:

imagepng

Add physical data source and semantic layer (DQL) data source to raqsoftConfig.xml

imagepng

In Jsp, the defined semantic layer file data source is called through the tag, and the Chinese field can be seen when the page is displayed.

imagepng

Self-Service Data Sources

The first three data sources are directly used by business users after the technical staff defines the data set. If the business user wants to define the data set by himself, it is also possible to set the fields to be analyzed. Of course, the technical staff must assist in setting Let's take a look at the metadata, because if the user is directly asked to operate the data in the database, the user cannot understand these complex table names and the relationship between them, and there is no way to start.

imagepng

imagepng

After the technician has set up the basic metadata dictionary file, set the corresponding file through the tag tag in the jsp. After publishing, the user can see the following interface. The left side is already an easily understandable Chinese name.

imagepng

imagepng

Business personnel can choose the fields they want to analyze by themselves, drag and drop to generate a new data set, and then enter the self-service report page to see the new data set and make reports.

imagepng

Access control

With the semantic layer, you can also control data permissions

imagepng

In the above figure, the category "Employee Analysis" can only see the data in the checked tables and fields

You can also control permissions for a table separately, and you can also control the same table. Different people see different data. For example, each sales can only see its own orders.

imagepng

At this point, the main functions are basically listed. If a self-service reporting tool has all the above capabilities, then the function can pass the test.

Summarize

How to realize the self-service report function in the application is actually the most difficult part: how to find a comprehensive and integrated tool. After this problem is solved, the remaining specific integration is not difficult for engineers, and now the problem is also It has been solved, stand on the shoulders of others, let’s not talk about looking higher and go further, at least it can save a lot of trouble, the next thing to do is to actually integrate it once, and personally verify it to see if it can satisfy myself. demand

Drying report information

Guess you like

Origin blog.csdn.net/u010634066/article/details/127066134