Information for creating JDBC connections
Use default values when you create JDBC connections if specific values are not provided. For more information, see the application server documentation.
WebLogic
Use the following values if your application server is WebLogic:
SQLServer
-
Database Driver: Microsoft™ MS SQL Server Driver (Type 4) Versions: 2012, 2012 SP1 and SP3, 2014, 2014 SP1, 2016 SP1
-
Default port: 1433
-
Driver class:
com.microsoft.sqlserver.jdbc.SQLServerDriver
-
Driver URL: jdbc:sqlserver://<your_db_host>[\\<named_instance>]:<your_db_port>;databaseName=<your_db_name>
-
Properties: Add user=<your_db_user_name>
Oracle
-
Driver: Other
-
Default port: 1521
-
Driver class:
oracle.jdbc.OracleDriver
-
Driver URL: jdbc:oracle:thin:@<your_db_host>:<your_db_port>:<your_db_service_name>
Enter the driver URL by using the format that is shown. Unica applications do not allow the use of Oracle's RAC (Real Application Cluster) format for JDBC connections.
- Properties: Add user=<your_db_user_name>
DB2®
-
Driver: Other
-
Default port: 50000
-
Driver class:
com.ibm.db2.jcc.DB2Driver
-
Driver URL: jdbc:db2://<your_db_host>:<your_db_port>/<your_db_name>
-
Properties: Add user=<your_db_user_name>
MariaDB
-
Driver: org.mariadb.jdbc.Driver
-
Default port: 3306
-
Driver class:
org.mariadb.jdbc.MariaDbDataSource
-
Driver URL: jdbc:mysql://hostname:port/databaseName
WebSphere®
Use the following values if your application server is WebSphere®:
SQLServer
Driver: N/A
Default port: 1433
Driver class:
com.microsoft.sqlserver.jdbc.SQLServerConnectionPoolDataSource
Driver URL:
jdbc:sqlserver://<DBhostName>:1433;databaseName=<DBName>
In the Database Type field, select User-defined.
After you create the JDBC Provider and data source, go to the Custom Properties for the data source, and add, modify properties as follows.
- serverName=<your_SQL_server_name>
- portNumber =<SQL_Server_Port_Number>
- databaseName=<your_database_name>
Add the following custom property:
Name: webSphereDefaultIsolationLevel
Value: 1
Datatype: Integer
Oracle
Driver: Oracle JDBC Driver
Default port: 1521
Driver class:
oracle.jdbc.OracleDriver
Driver URL: jdbc:oracle:thin:@<your_db_host>:<your_db_port>:<your_db_service_name>
Enter the driver URL by using the format that is shown. Unica applications do not allow the use of Oracle's RAC (Real Application Cluster) format for JDBC connections.
Add the following custom property:
Name: webSphereDefaultIsolationLevel
Value: blank or 2
Datatype: Integer
DB2®
Driver: JCC Driver Provider
Default port: 50000
Driver class:
com.ibm.db2.jcc.DB2Driver
Driver URL: jdbc:db2://<your_db_host>:<your_db_port>/<your_db_name>
Add the following custom property:
Name: webSphereDefaultIsolationLevel
Value: 2
Datatype: Integer
- Driver:
MariaDBDriver
(this is the mariadb jar registered with mariadb) - Default port:
3306
- Driver class:
org.mariadb.jdbc.MariaDbDataSource
- Driver URL:
jdbc:mariadb://<your_db_host>:<your_db_port>/<your_db_name>jdbc:db2://<your_db_host>:<your_db_port>/<your_db_name>
JBoss
Specify the native library path of the database driver JAR file on your server. For example: db2jcc4.jar/ojdbc8.jar/sqljdbc4.jar.
Use the following values if your application server is JBoss:
SQLServer
- Database Driver: Microsoft MS SQL Server Driver (Type 4) Versions: 2012, 2012 SP1 and SP3, 2014, 2014 SP1, 2016 SP1
- Default port: 1433
- Driver class:
com.microsoft.sqlserver.jdbc.SQLServerDriver
- Driver URL: jdbc:sqlserver://<your_db_host>[\\<named_instance>]:<your_db_port>;databaseName=<your_db_name>,valid-connection-checker-class-name =org.jboss.jca.adapters.jdbc.extensions.mssql.MSSQLValidConnectionChecker
For example :/subsystem=datasources/data-source=UnicaPlatformDS:add(jndi-name="java:/UnicaPlatformDS",connection-url="jdbc:sqlserver://localhost:1433;databaseName=plat11",driver-name=sql,user-name=sa,password=test1234,valid-connection-checker-class-name="org.jboss.jca.adapters.jdbc.extensions.mssql.MSSQLValidConnectionChecker")
Oracle
- Driver: Oracle JDBC Driver
- Default port: 8232
- Driver class:
oracle.jdbc.OracleDriver
- Driver URL: jdbc:oracle:thin:@<your_db_host>:<your_db_port>:<your_db_service_name> valid-connection-checker-class-name=valid-connection-checker-class-name="org.jboss.jca.adapters.jdbc.extensions.oracle.OracleValidConnectionChecker"
For example:/subsystem=datasources/data-source=UnicaPlatformDS:add(jndiname=" java:/UnicaPlatformDS",connection-url="jdbc:oracle:// localhost:8232;databaseName=plat11",driver-name=oracle,username= plat,password=test1234,valid-connection-checker-class-name="org.jboss.jca.adapters.jdbc.extensions.oracle.OracleValidConnectionChecker")
DB2
- tomcat
- Driver: JCC Driver Provider
- Default port: 50000
- Driver class:
com.ibm.db2.jcc.DB2Driver
- Driver URL: jdbc:db2://<your_db_host>:<your_db_port>/<your_db_name> valid-connection-checker-class-name="org.jboss.jca.adapters.jdbc.extensions.db2.DB2ValidConnectionChecker"
For example:/subsystem=datasources/data-source=UnicaPlatformDS:add(jndiname=" java:/UnicaPlatformDS",connection-url="jdbc:db2:// localhost:50000;databaseName=plat11",driver-name=db2,username= plat,password=test1234,valid-connection-checker-class-name="org.jboss.jca.adapters.jdbc.extensions.db2.DB2ValidConnectionChecker"
- Driver:
MariaDBDriver
(this is the mariadb jar registered with mariadb) - Default port:
3306
- Driver class:
org.mariadb.jdbc.MariaDbDataSource
- Driver URL:
jdbc:mariadb://<your_db_host>:<your_db_port>/<your_db_name>jdbc:db2://<your_db_host>:<your_db_port>/<your_db_name>
Tomcat
Specify the native library path of the database driver JAR file on your server. For example: db2jcc4.jar/ojdbc8.jar/sqljdbc4.jar to create a datasource under Tomcat Interact Instance, add folder hierarchy as <Tomcat_Home>/conf/ Catalina/localhost, create a xml file with the name interact.xml under localhost folder. Add data source pointing to Runtime, Test, Production and learning database in interact.xml, refer platform or Campaign xml file which is created through installers under there respective Tomcat instance directory. You will need to create these Data source entry in Campaign Tomcat instance too.
Set removeAbandoned=true and
removeAbandonedTimeout=300 (5 minutes) for plands
datasource configuration in <catalina
home>/conf/Catalina/localhost/plan.xml file within the section that starts with the
parameter Resource name="plands".
<Resource name="plands" auth="Application" type="javax.sql.DataSource" factory="org.apache.tomcat.jdbc.pool.DataSourceFactory" maxTotal="100" maxIdle="30" maxWaitMillis ="10000" username="abc" password="abc" driverClassName="org.mariadb.jdbc.Driver" removeAbandoned="true" removeAbandonedTimeout="300" url="jdbc:mysql://lp2-ap-51728467.prod.hclpnp.com:3306/pln121" />
300
seconds of execution time, change the value of
removeAbandonedTimeout.Use the following values if your application server is Tomcat:
SQLServer
- Database Driver: Microsoft MS SQL Server Driver (Type 4) Versions: 2012, 2012 SP1 and SP3, 2014, 2014 SP1, 2016 SP1
- Default port: 1433
- Driver class:
com.microsoft.sqlserver.jdbc.SQLServerDriver
- Driver type:
javax.sql.DataSource
- Driver URL: jdbc:sqlserver://<your_db_host>[\\<named_instance>]:<your_db_port>;databaseName=<your_db_name>
Oracle
- Driver: Oracle JDBC Driver
- Default port: 1521
- Driver class:
oracle.jdbc.OracleDriver
- Driver URL: jdbc:oracle:thin:@<your_db_host>:<your_db_port>:<your_db_service_name>
DB2
- Driver: JCC Driver Provider
- Default port: 50000
- Driver class:
com.ibm.db2.jcc.DB2Driver
- Driver URL: jdbc:db2://<your_db_host>:<your_db_port>/<your_db_name>
- Driver:
MariaDBDriver
(this is the mariadb jar registered with mariadb) - Default port:
3306
- Driver class:
org.mariadb.jdbc.MariaDbDataSource
- Driver URL:
jdbc:mariadb://<your_db_host>:<your_db_port>/<your_db_name>jdbc:db2://<your_db_host>:<your_db_port>/<your_db_name>