Data Source Creation

You can create data source connections to databases.

A data source defines the physical connection to a database. A data source connection specifies the parameters needed to connect to a database, such as the location of the database and the timeout duration. These parameters form a connection string for the data source.

You can create data sources in the portal or in Framework Manager. Because they are stored on the server, data sources appear in both places, regardless of where they were created. Existing data source connections can be edited only in the portal.

If you are an administrator, you can set up all required data sources before models are created in Framework Manager so that all connections are available in the Framework Manager Metadata wizard.

Data sources are stored in the Cognos® namespace and must have unique names. For example, you cannot use the same name for a data source and a group.

You can include authentication information for the database in the data source connection by creating a signon. Users need not enter database authentication information each time the connection is used because the authentication information is encrypted and stored on the server. The signon produced when you create a data source is available to the Everyone group. Later, you can modify who can use the signon or create more signons.

Before creating data sources, you must have write permissions to the folder where you want to save the data source and to the Cognos namespace. You must also have execute permissions for the Data Source Connections secured feature.

Using JDBC Connections for Data Sources

For some data source connections, you can provide additional Java™ database connectivity (JDBC) data source connection information. JDBC data source connection information is optional.

JDBC data source connections are required if your packages are published from Framework Manager with the Use Dynamic Query Mode option enabled.

The JDBC connection strings for relational data sources have the following format:

^User ID:^?Password:;LOCAL;JD;URL=<urlspec>;
DRIVER_NAME=<driver class name spec>[;CognosProperty=value[;...]]

For example, the JDBC connection string for a Microsoft SQL Server data source might look like this:

^UserID:^?Password:;LOCAL;JD-SS;URL=jdbc:sqlserver://sotaimpqc05:1433;
databaseName=dmsqc1;DRIVER_NAME=com.microsoft.sqlserver.jdbc.SQLServerDriver;
LOCALSORT=us_us_ASCII;LEVEL=PRIMARY

For information on Query Service settings, see the Query Service Administration.

Note that isolation levels are not implemented for JDBC connections. You may see different behaviour if the isolation level that you choose for the native client connection is different from the default one used by the JDBC driver. Consult your JDBC driver documentation for details on the driver default.

For more information on isolation levels, see Specifying Isolation Levels .

Recommendation - Use Network Paths For File-Based Data Sources

If you have a distributed installation with several servers, we recommend that you use network paths for all file-based data sources rather than local paths. This ensures that the data sources can be accessed by the services that require them, regardless of which server requires the data.

When you create a connection to a file-based data source, such as a PowerCube, you enter a path and file name. To point to the file, use a local path, such as C:\cubes\Great Outdoors Company.mdc, or a network path, such as \\servername\cubes\Great Outdoors Company.mdc.

In a distributed installation, where report servers are running on different computers, using a local path requires that the file and path be valid on each computer where a report server is running. Alternatively, if you use a network path to point to a file, each report server points to the same file on the network without having the file available locally. Also, to ensure that the file is always available, we recommend that you store it in a shared directory that can be accessed on your network.

If you installed IBM Cognos Business Intelligence components on UNIX operating system servers, we recommend that you also locate the file-based data source on a UNIX server. You should then use a UNIX path, such as /servername/cubes/Great Outdoors Company.mdc to access the file.

If you have installed all components on a single computer, you can use local paths, but you must ensure that the services requesting the data have the appropriate access to the data files on the computer.

For Microsoft Windows operating system distributed installations, we recommend that you use UNC paths to shared directories for any file based data source, such as PowerCubes or XML files.