Database drivers and database connection URLs
The following details and examples show how the database connection URL is constructed.
Database | Driver name |
---|---|
Oracle (DataDirect Driver) | tibcosoftwareinc.jdbc.oracle.OracleDriver |
Oracle (Oracle JDBC Thin Driver, ojdbc*.jar) | oracle.jdbc.OracleDriver |
Microsoft SQL Server (DataDirect Driver) | tibcosoftwareinc.jdbc.sqlserver.SQLServerDriver |
Microsoft SQL Server (Microsoft JDBC Driver, sqljdbc*.jar) | com.microsoft.sqlserver.jdbc.SQLServerDriver |
PostgreSQL driver postgresql*.jar | org.postgresql.Driver |
Component | Description |
---|---|
API | Specifies which API to use. This is always jdbc. |
Database Driver | Specifies which database driver to use to connect to the database. Default tibcosoftwareinc, which will use the Spotfire DataDirect driver. If you have installed a different driver, you may provide this here. |
Server Type | Specifies the type of database server. Either sqlserver or oracle.
Note: Server Type is only applicable when using the DataDirect driver.
|
Hostname | Specifies the hostname of the database server. |
Port | Specifies the port which the database server listens to; for example 1433. |
Database name, SID, or service name | Specifies the name (MSSQL, PostgreSQL), SID (Oracle) or Service Name (Oracle) that defines your Spotfire database. |
Options | Specifies further options, separated with semicolons. Only necessary if you want to set something specific for your database server, such as a named Instance in an MSSQL server. See the following examples. |
Database driver | URL structure | Examples |
---|---|---|
Oracle (DataDirect Driver) | [API]:[DBDriver]:[ServerType]://[Hostname]:[Port];SID=[SID] | jdbc:tibcosoftwareinc:oracle://dbsrv.example.com:1521;SID=spotfire |
Oracle (DataDirect Driver) | [API]:[DBDriver]:[ServerType]://[Hostname]:[Port];ServiceName=[Service Name] | jdbc:tibcosoftwareinc:oracle://dbsrv.example.com:1521;ServiceName= pdborcl.example.com |
Oracle (Vendor Driver, ojdbc*.jar) | [API]:[DBDriver]:[DriverType]://[Hostname]:[Port]:SID | jdbc:oracle:thin:@dbsrv.example.com:1521:orcl |
Oracle (Vendor Driver, ojdbc*.jar) | [API]:[DBDriver]:[DriverType]://[Hostname]:[Port]/[ServiceName] | jdbc:oracle:thin:@//dbsrv.example.com:1521/pdborcl.example.com |
Microsoft SQL Server (DataDirect Driver) | [API]:[DBDriver]:[ServerType]://[Hostname]:[Port];DatabaseName=[DBName] | jdbc:tibcosoftwareinc:sqlserver://dbsrv.example.com:1433;DatabaseName= spotfire_server
Example using NTLM Authentication: jdbc:tibcosoftwareinc:sqlserver://dbsrv.example.com:1433;DatabaseName= spotfire_server;AuthenticationMethod=ntlmjava |
Microsoft SQL Server (Vendor Driver, sqljdbc*.jar) | [API]:[DBDriver]://[Hostname]:[Port];DatabaseName=[DBName] | jdbc:sqlserver://dbsrv.example.com:1433;DatabaseName=spotfire_server;selectMethod= cursor
Example: Making sure that the driver always returns prevents infinite waits during adverse conditions jdbc:sqlserver://dbsrv.example.com:1433;DatabaseName=spotfire_server;lockTimeout= <X, where X is a good value> Note: Due to a restriction in the vendor Microsoft SQL Server driver, you may need to add the option
responseBuffering=adaptive to your connection string. This is necessary if you are going to store large analysis files in the library.
Example: Using
jdbc:sqlserver://dbsrv.example.com:1433;databaseName=spotfire_server;selectMethod= cursor;responseBuffering=adaptive Example: Using Integrated Authentication jdbc:sqlserver://dbsrv.example.com:1433;DatabaseName=spotfire_server;selectMethod= cursor;integratedSecurity=true; |
PostgreSQL | [API]:[DBDriver]://[Hostname]:[Port]/[DBName] | jdbc:postgresql://dbsrv.example.com:5432/spotfire_server |