This topic applies to the Admin Console > Data > Sources settings.
Data Sources establish the connection between Exago and a database or a web service. Although typically only one database is used, Exago can join data from different sources into a single report.
To utilize some types of data sources, the appropriate driver may need to be downloaded and installed separately from the Exago install process. Refer to Data Source Drivers.
Creating, Editing or Deleting Data Sources
To add a new data source click Sources in the Main Menu and either:
click the Add icon at the top of the main menu
right-click and select Add from the context menu
To edit a source either:
double click it
select it and click the Edit icon at the top of the main menu
right-click it and select Edit from the context menu
To delete a source either:
select it and click the Delete icon at the top of the main menu
right-click it and select Delete from the context menu
To save changes and new objects click the Apply or Okay buttons.
Data Source Properties
Creating a new Data Source in the Admin Console in v2021.2+
Creating a new Data Source in the Admin Console in pre-v2021.2
Each data source must have the following:
Name
A friendly name for the Data Source that will be referenced in the application.
Type
The type of source being used. Valid types include:
Relational databases
SQL Server — Microsoft SQL Server
MySQL
Oracle
Postgres — PostgreSQL
DB2 — IBM db2
Informix — IBM Informix
ODBC — ODBC Driver
SQLitev2021.1.8+
Other
File — XML or Excel file (For more information see Excel and XML Files.)
.NET Assembly — .NET Assembly DLL (For more information see .NET Assemblies.)
MS OLAP — OLAP (For more information OLAP and MDX Queries.)
Not currently supported:
ElasticSearchv2018.2+ — ElasticSearch/ELK database (For more information see CData Drivers.)
Google BigQueryv2021.1.10+ (For more information see CData Drivers.)
Data warehouses
Redshiftv2019.1.11+
Snowflakev2019.1.9+
Non-relational databases
MongoDBv2018.2+
Important:
As of v2024.2.1, CData drivers are no longer available for use in Exago BI products. See CData Drivers.
Schema/Owner Name (blank for default)
If using schema to provide multi-tenant security, provide a database schema. Otherwise, leave this field blank. For more information, review Multi-Tenant Environment Integration.
Connection String Input
Describes how Exago shall connect to the Data Source. Typically, a server name or IP address, database name and login credentials are specified here. Different Data Source types have different connection string requirements, although the most common connection string parameters are:
Server — the server host name or IP address where the database is physically located
Database — the name of the database on the Server
User ID and Password — the user name and password credentials to access the Database
Choose either the integrated Connection String Builder (Parameterized mode), or to provide a connection string manually (String mode) from the Connection String Input dropdown. Switching between Parameterized and String is possible, and Exago will remember the last mode selected. The Data Source connection is still stored as a standard connection string in the configuration file regardless of mode selected.
Some Data Source types only support Parameterized or String mode. In these cases, Exago will select the correct mode and disable the Connection String Input dropdown.
In Parameterized mode, Exago queries the database driver for all of the available connection string options/parameters. Then, these parameters may be added one at a time in key-value format to build a complete connection string.
If the database driver does not return any connection string parameters, the parameter names must be manually typed instead of chosen from a dropdown list.
Adding the Port connection string parameter to a Data Source by choosing its name from the Parameter Name dropdown
To add a new connection string parameter to the Data Source:
Click the Add Connection Parameter button.
Enter the name of, or choose the name of a parameter from the dropdown list.
Provide a value for the parameter in the space provided.
To hide/show a connection string parameter, click the Make Connection String Visible or Connection String Hide icons accordingly.
To remove a connection string parameter, click the Delete icon at the end of the line. This icon is only visible when there are two or more parameters for a Data Source.
Connection strings vary by type:
Type
Connection Strings
mssql, oracle, postgres, mysql sqlite (v2021.1.8+) and olap
If using Integrated Authentication from an IIS Application Pool to connect to a remote MSSQL or Microsoft SQL Server Analysis Services (SSAS) server, review these MSDN and Stack Overflow topics to ensure the correct credentials are sent to the SQL server.
The database driver specified in Database Settings determines the character set used in the application. If the data in the data source uses a different character set, it should be explicitly set in the connection string.
For PostgreSQL data sources using the Npgsql driver and all lowercase schema names, set the UseDelimitersOnSchema directive in dbconfigs.override.json to true for best results. See the Overriding dbconfigs Information.
assembly
Required parameters:
assembly – The full path of the assembly name.
class – The class name in the assembly where the static methods will be obtained.
file
Requires the physical path to the Excel or XML file and the file type. Example:File=C:\example.xls;Type=excel;
.NET Assemblies can be used as data sources. This is possible when the .NET Assemblies underlying methods are setup as data objects.
An advantage of doing this is being able to use high-level language to manipulate the data being reported on at run-time. The main disadvantage is not being able to take advantage of the database to perform joins with other data objects; data from methods can still be joined, but the work to do this is done within Exago.
Parameters
Parameters are passed from Exago to .NET Assemblies. Three types of parameters can be passed but only Call Type is required.
Call Type (required)
Integer that specifies what Exago needs at the time of the call. There are three possible values. You may specify the name of this parameter in the Programmable Object Settings of the General section.
0 : Schema – returns a DataSet with no rows.
1 : Data – returns a full DataSet.
2 : Filter Dropdown Values – returns data for the filter dropdown list. The Data Field being requested is passed in the column parameter. The filter type is passed in the filter parameter (see below).
Column, Filter and Sort Strings
To optimize performance Exago can pass user-specified sorts and filters to the .NET Assembly. This process reduces the amount of data sent to Exago. If these parameters are not used, all of the data will be sent to Exago to sort and filter. Column, filter and sort strings are sent as standard SQL. You may specify the name of these parameters in the General > Programmable Object Settings section.
Custom Parameter Values (optional)
Additional parameters can be specified to be sent to individual methods in the Data Object Menu.
To increase performance, when a .NET Assembly is first accessed it is compiled and cached within Exago. Therefore, Exago will not be aware of any changes within .NET Assembly. If the assembly is subsequently changed, reset the internal cache by clicking the Test Connectionicon restarting the web server.
If an Exago .NET API application needs to access reports with an assembly data source, it must include a reference to the assembly WebReportsAsmi.dll.
SessionInfo (optional) v2016.2+
Session state variables. See SessionInfofor more information.
.NET Assemblies
It is important to note that when a connection string for .NET Assembly is set the class name must match the name of the class where the static methods will be searched. UNC or absolute paths may be used. Make sure that the assembly has read privileges for the IIS user running Exago. Below is an example of a .NET Assembly connection string:
.NET Assembly methods must be static. Below is an example of a .NET Assembly method.
public class Main {
public static DataSet dotnet_optionees(int callType, string columnStr, string filterStr, int myCustomParameter) {
switch (callType) {
case 0: // return schema
case 1: // return data
case 2: // return filter values for dropdown
}
}
}
Method signature using SessionInfo (v2016.2+):
public class Main {
public static DataSet dotnet_optionees(WebReports.Api.Common.SessionInfo sessionInfo, int callType, string columnStr, string filterStr, int myCustomParameter) {
switch (callType) ...
}
}
Excel and XML Files
Exago can read Microsoft Excel workbooks and XML files as Data Sources.
Excel workbooks and XML files will have less speed, performance, and security of a database. Using Excel and XML files is recommended only if the data set is small or if the information is only available in this format.
Excel
Each worksheet in the Excel file will be read as a separate table with the sheet name as the table’s name. The top row will be read as the column headers, and the remaining cells will be read as the data. Do not leave any blank rows or columns.
Connection String Example
File=C:\example.xls;Type=excel;
XML
The XML document must begin with the schema. After defining the schema the data must be placed into the appropriate tags. For reference see the working example below:
Exago can query OLAP Data Sources using MDX Queries. OLAP Data Sources and Objects are identical to a regular data base type object, with the following exceptions:
Data Objects belonging to OLAP type Data Sources must have their Schema Access Type set to Metadata and must have Column Metadata set for all fields.
OLAP Data Objects will always be MDX Queries written in the Custom SQL Object dialog. These queries are passed directly through to the data source. Exago simply passes through the MDX query to the data source and does not modify it in any way. Therefore, all filtering and sorting are done in memory, tenanting at the data object level and database aggregation do not work with OLAP data sources.
Connecting to a Microsoft SQL Server Analysis Services (SSAS) data source will use Integrated Authentication. See the notes in the Connection String Input section above how to handle this situation. In a general sense, the IIS Application Pool will need to login with a credential assigned in an appropriately provisioned SSAS role on the data source.
Sample Connection String
Data Source=SERVER1MSSQLSERVER2014;Catalog=AdventureWorksDWAnalysis;
The Catalog parameter should match the Database name in Microsoft SQL Server Management Studio.
Using Azure based SSAS
In order to use an Azure based Microsoft SQL Server Analysis Services Database (SSAS) you need the most up to date ADOMD.NET driver, which is available from Microsoft. Then, in order to properly configure Data Object entities through joins, the following information must be provided:
The entity containing the primary key should be specified in the “From” section.
The entity containing the foreign key should be specified in the “To” section.
The IDs used in the join configuration must be included in the metadata fields and should be available in the design model.
ODBC Drivers
Exago can use ODBC drivers to connect to data sources. When connecting to an ODBC data source, an extra option will appear to set the Column Delimiters. The delimiter character depends on which type of data base you are connecting to.
Examples
MySql
' (grave accent)
MsSql, OLAP
[] (brackets)
DB2, Informix, Oracle, Postgres, Sqlite
" (quotation marks)
If your data objects have spaces in their names, you must set the correct delimiter in order to access the data. Otherwise, improper SQL will be generated and you will see errors or erroneous data.
CData Drivers
Important:
As of v2024.1.2, CData drivers are no longer available for use in Exago BI products. See CData Drivers.
As of v2018.2+, Exago BI allows for additional data source types through CData ADO.NET drivers. For more information, see CData Drivers.