Createlocalconnection: Save a JDBC Connection

The createlocalconnection CLI command for Essbase creates a JDBC connection and stores it locally. To use this command, you need Service Administrator role.

Description

A service administrator must use this command to create and save the local connection before anyone can use the CLI dataload or dimbuild commands with the streaming option. You must also set an environment variable EXTERNAL_CLASSPATH to point to the .jar file for your database driver (see Build Dimensions and Load Data by Streaming from a Remote Database).

Syntax

createLocalConnection [-verbose] -name streamConnection -connectionstring  connectionString -user userName [-driver jdbcDriver] [-password password]
Option Abbreviation Description
-verbose -v Show extended descriptions
-name -N Connection name
-connectionstring -cs JDBC connection string. Format can be with SID, as follows:
jdbc:oracle:thin:@host:port:SID

or with service name, as follows

jdbc:oracle:thin:@host:port/service_name

The syntax formats above apply for Oracle Database. See Examples section for minor differences in the connection string syntax when you are working with other providers.

-user -u User name
-driver -D JDBC driver. If not provided, Oracle Database is considered the default, as oracle.jdbc.driver.OracleDriver
-password -p Password (optional)

If you have network connectivity between an external source of data and Essbase, it is most efficient to define application-level or global connections and Datasources in the Essbase web interface. These definitions help you to easily "pull" data from the external source. If you have no network connectivity between Essbase and the external source of data, then you can stream data loads or dimension builds using the CLI by first using this command to create a local connection, and then issuing the dataload or dimbuild command with the stream option.

Notes

After migrating to Release 21.4 or higher, the Service Administrator needs to recreate any saved local connections that were created using this command in a previous release.

Examples

If the -driver option and jdbcDriver parameter are not provided, Oracle database is the assumed database by default.

esscs createLocalConnection -N OracleDBConnection1 -cs jdbc:oracle:thin:@myhostname01:1521:ORCL -u OracleUser -D oracle.jdbc.driver.OracleDriver

If the -driver option and jdbcDriver parameter are not provided, Oracle database is the assumed database by default.

esscs createLocalConnection -N OracleDBConnection2 -cs jdbc:oracle:thin:@host1.example.com:1521/ORCL.esscs.host1.oraclecloud.com -u OracleUser

If the -driver option and jdbcDriver parameter are not provided, Oracle database is the assumed database by default.

esscs createLocalConnection -N DB2conn -cs jdbc:db2://myhostname02.example.com:50000/TBC -u myDB2User -D com.ibm.db2.jcc.DB2Driver

If the -driver option and jdbcDriver parameter are not provided, Oracle database is the assumed database by default.

esscs createLocalConnection -N MySQLconn -cs jdbc:mysql://myhostname03.example.com:3306/tbc -u MySQLUsr -D com.mysql.jdbc.Driver

If the -driver option and jdbcDriver parameter are not provided, Oracle database is the assumed database by default.

esscs createLocalConnection -N MSSQLConn -cs jdbc:sqlserver://myhostname04.example.com:1433 -u MSSQLUsr -D com.microsoft.sqlserver.jdbc.SQLServerDriver

If the -driver option and jdbcDriver parameter are not provided, Oracle database is the assumed database by default.

esscs createLocalConnection -N TeraDconn -cs jdbc:teradata://myhostname05.example.com/DBS_PORT=1025 -u TeraUsr -D com.teradata.jdbc.TeraDriver