Resources¶
Easy Report knows how to make reports on tables (resources in the Service's terminology) loaded from data sources. Here you will find all the necessary information on how to work with the resource.
Creating a resource¶
Selecting a data source¶
You must select or create the data source from which the resource will be loaded.
Selecting a table¶
After selecting a data source, Easy Report prompts you for a list of its tables. To familiarize yourself with the supported table formats within a particular source, please go to the data sources page.
Resource parameters¶
1. Name¶
Using this name bot users will be able to activate the resource for building business reports based on its data.
Tip
Choose friendly names in your language, which the bot user will be able pronounce.
2. Resource Group¶
Select or create a group in which the resource will be included. Bot users can only access resources that are in the group available to them.
3. Update Frequency¶
Specify how often the resource's source data is updated. The following update policies are supported:
- Manual update (by button).
- Scheduled:
- Updating disabled.
- Once an hour (00:00, 01:00, ..., 23:00)
- Once a day (01:00:00)
4. Incremental Update¶
Tip
This update format is supported by data sources that have the ability to give part of the data at the request of the client. For example, databases.
You can increase the data update rate for large tables by using incremental update. When you enable this mode, our system will not request the whole data array from the source, but only a part of the data for the last (specified in the settings) period. If necessary (for example, if the source table structure has changed) you can run full update of data for the whole period on the resource page.
Incremental update options:
- Enable/disable this mode.
- Column, in relation to which the data will be selected for updating. Valid types for this column: "Date", "Date and time".
- Update period, counted back from the current date, is used to limit the data to be updated.
It is set in the format: Value - positive integer; Format - Day, Month or Year.
- Storage period, counting backwards from the current date, is used to limit the amount of data stored. All data preceding the calculated date will not be taken into account in the system.
It is set in the format: Value - positive integer; Format - Day, Month or Year.
Example¶
Set an update period of 1 month, a retention period of 1 year, and a daily update frequency.
The date is March 28, 2020. The data from no earlier than February 1, 2020 will be updated, and stored from no earlier than January 1, 2019.
April 1, 2020. The data from no earlier than March 1, 2020 will be updated, and stored from no earlier than January 1, 2019.
Date January 1, 2021. The data from no earlier than December 1, 2020 will be updated, and stored from no earlier than January 1, 2020.
5. Create a metamodel automatically¶
Our system will analyze the selected table and create a simple metamodel for a quick start. You can disable this option if you want to create the metamodel manually after creating the resource.
The automatically generated metamodel contains the following entries:
- Attributes on columns with no more than 1000 unique values. You will be able to add the attributes for other columns after creating the resource manually.
- Values, which will be calculated for all columns with numeric types.
Tip
If your table contains columns of numeric type that are not values (for example, identifiers that cannot be aggregated), you can delete such erroneous entries in the metamodel manually after creating the resource.
- Date will be selected if at least one column with the type "Date" is found.
Limitations on the amount of data¶
Limit on the amount of data that can be loaded:
- 500 mb if the data source does not support giving away the resource structure (cloud file storages).
- No limit if the data source supports structure push (all other sources).
Resource groups¶
Resources can be combined into groups for further differentiation of rights to them. This functionality is intended to simplify the maintenance of access rights: the bot user sees only those resources that are contained in the groups assigned to him.
Tip
A resource can be part of several groups at the same time. Deleting any group does not delete the resource itself.
There is also another access rights management feature in Easy Report that works in conjunction with resource groups - security filters.
Metamodel¶
The metamodel is the central entity of the service. Each metamodel item is a layer between the natural speech and the resource column. The metamodel entry specifies a set of labels for the column, by which the service will parse the query. Can consist of several words (example: Department, Payment Forecast).
There are 4 types of records in the metamodel, for each type different additional settings are available:
Attribute¶
This column contains a limited set of records (usually text records). Example: Departments attribute with records Accounting, Sales, IT etc.
The following settings are available for the attributes:
- Dictionary - allows the user to filter data by specific values. Usually columns with a small number of unique values are used as dictionary.
A column containing more than 1000 unique values is perceived by the system as potentially high-cardinal. The system will ask you to confirm the choice of the column as a Dictionary allows the user to filter data by specific values. Usually columns with a small number of unique values are used as dictionary.
Example
The resource has a "Supplier" column that contains 8 unique values. The probability that the user will want to filter the data by a particular supplier is quite high. It's better to make such a column into a Dictionary.
The resource has a "Product" column, which contains 1515 unique values. Despite the fact that the volume of the potential Dictionary is large, we know that the user will want to filter data on a particular product. Such a column can be made into a Dictionary.
The resource has a column called "Check Number", which contains 150,000 unique values. The volume of potential Reference is very large, because the number of unique values will be commensurate with the number of rows in the table. It is unlikely that the user will want to filter data by check number, as most likely he does not even know it. Such column must not be (the usefulness of such a Dictionary will be little, and the speed of forming the report will fall markedly) to make a Dictionary.
- Smart Filter - allows you to filter without explicitly specifying an attribute label.
It is recommended to switch off Smart filter for very large Dictionaries, to avoid casual searches on this feature.
- Type - defines the type of content in the Dictionary. At the moment two types of Dictionaries are supported: Default (any Dictionary), Full name.
This is an optional setting that helps to handle names in some language groups that have declensions.
- Sorting - allows you to set a specific sort order for the attribute (by default they are sorted in ascending order).
- Order in the report - allows you to set a hierarchy of attributes when displaying reports. The attribute with a higher priority will be positioned on the left side.
Tip
The order may be empty or equal. In this case the attributes will be sorted in the order they appear in the query. For example, "Sales by suppliers and departments " or "Sales by departments and suppliers " in case of same priorities the attributes "Supplier " and "Department " will be output in different order.
- Separator - allows you to extract correctly the values of Dictionaries in case they are given in the data in the form of one-to-many relation.
Example.
The row in the data is one order and there is a Dictionary "Product ", which lists all the Products in the order, represented in the format "Pens/Pencils/Paper ". For this example "/"" is the separator and allows you to process the information correctly for correct search filters. When requesting "Show orders with paper " the service will show the necessary orders, in which one of the goods was "Paper ".
- Personalization - a marking for the service that the personalized filter ("Show my orders", "How many I have sold") should be retrieved for this Dictionary.
The search will be performed by the name and surname of the bot user (the order of the words in the Dictionary is not important and does not have to match the order in the Easy Report service). There can be several personalized attributes, the search will be carried out sequentially in order of priority.
Value¶
This is a quantitative characteristic (example: Payments). It supports the following set of aggregations:
- sum
- average
- count
- count unique
- minimum
- maximum
- remaining
- any
The following settings are also active for values:
- Accuracy - rounds the corresponding value to N decimal places.
- Sorting - allows you to set a specific sorting order (by default, they are sorted in descending order).
- Units - sets the format for displaying the unit of measure.
- Order in the report - allows you to set the hierarchy of values in the report output. The value with higher priority will be placed on the left side.
Tip
For values and custom values, the common order of priorities is formed. The common order of metamodel elements in the report is as follows, each group is sorted by priority:
- Dates
- Attributes
- Values and custom values
- Default value - a check mark for the service to use this value by default, if no value or custom value was specified in the request. There can be several for the resource.
- Priority at TOP N - a check mark for the service to sort rows in the report by this value for TOP N requests. There can be several for a resource, then the sorting will be performed in order of priority.
Custom value¶
This is an individually created value that is calculated using a specified formula.
Custom values are needed for calculations on preaggregated data, for example, to calculate relative values on any drillthrough (for example, "profitability by client", "profitability by project", etc.).
To create such a custom value you need to:
- Select the columns that will participate in the calculation formula.
- Using special calculator enter the formula, which will be used for calculation.
The following settings are also active for custom values:
- Accuracy - rounds the corresponding calculation value to N decimal places.
- Sorting - allows you to set a specific sorting order (by default they are sorted in descending order).
- Units - sets the format for displaying the unit of measure.
- Order in the report - allows you to set the hierarchy of custom values in the report output. The value with higher priority will be placed on the left side.
- Default value - the mark for the service to use this custom value by default, if no value or custom value was specified in the request. There can be several for the resource.
- Priority at TOP N - the mark for the service to sort rows in the report by the given custom value at TOP N requests. There can be several for a resource, then the sorting will be performed in order of priority.
Date¶
Can be in date or datetime format.
The following settings are also active for date:
- Sorting - allows you to set a specific sort order for the date (by default sorted in descending order).
- Order in the report - allows you to set the hierarchy of dates when displaying reports. The date with the higher priority will be placed on the left side.
- Default period - defines the format in which the default date will be displayed (Day, Month or Year). The format can be changed dynamically in the request, for example, "Orders by creation date year".
- Autofilter by current period - adds an automatic filter to the report by the current Period by default when there is no filter or drillthrough by dates in the query.
Shortcuts¶
Shortcuts allow to output several elements of a metamodel in the report by one label.
For example, you can set the following columns to be output by the "Order" label: "Order Number", "Seller", "Merchandise" and "Order Amount".
Dictionaries¶
For the attributes that have been marked as Dictionaries, you can add additional labels for correlated filter searches. For example, for the Order Status Dictionary, the values are technical codes "DON", "CNL", etc.
On the Dictionaries tab, you can select the Dictionary "Order Status " and add tags "Delivered", "Completed ", etc. for the status "DON ".
Tips¶
Tips allow you to display additional information in the report that allows the user to correctly interpret the data.
For example, if the report contains the "Sales" indicator, the service can additionally display a message with the following hint: "Sales are given including all compensations, adjustments and discounts".
To configure the tip you must:
- Choose necessary elements of the metamodel and form a condition formula with them in a special condition calculator.
- Add tip text (supports Markdown markup).
- Add quick actions to be added as buttons under the report.
Example
We want to remind the user that he sees information on all order statuses if no filter or drillthrough by that attribute has been used. To do that we create a tip with the condition "not Order status ", with the text "Order status: all (you can always filter or drillthrough the report. For example, by writing "Leave only delivered") and a quick action "Leave only delivered ".