This page last changed on Feb 25, 2008 by alui.
Bamboo provides two ways to connect to an MS SQL Server database — via JDBC or via a datasource. JDBC is generally simpler and is the recommended method.
Error formatting macro: toc: java.lang.NullPointerException
Connecting via JBDC
To connect Bamboo to a MS SQL Server database, via JDBC,
- Copy the MS SQL Server JDBC driver jar (download here) file into your application server's classpath:
- For the Bamboo Standalone distribution, copy the jar file into the webapp/WEB-INF/lib directory.
- For the Bamboo EAR-WAR distribution, the location will depend on which application server you are using.
- At Step 2 of the Bamboo Setup Wizard, choose 'External Database' and select 'MSSQL' from the list.
- The 'Select Database Connection' screen will appear. Select 'Direct JDBC connection'.
- The 'Setup JDBC Connection' screen will appear as shown in the screenshot below.
- 'Driver Class Name' — Type the following: net.sourceforge.jtds.jdbc.Driver
- 'Database URL' — Type the URL where Bamboo will access your database. For syntax, please see this MS SQL Server documentation
e.g: jdbc:jtds:sqlserver://localhost:1433/<database>
- 'Username' — Type the username that Bamboo will use to access your database.
- 'Password' — Type the password that Bamboo will use to access your database.
- Select the 'Overwrite existing data' checkbox if you wish Bamboo to overwrite any tables that already exist in the database.
 | Mixed mode Windows Authentication. On a typical MS SQL Server installation, 'Windows Authentication' mode is the default security mode. This means that if you try to connect to the database with a database user, MS SQL Server will throw the following error, "Login failed for user 'sa'. Reason: Not associated with a trusted SQL Server connection." To resolve this, you can either,
- Enable 'Mixed Mode Authentication'
- Log in with a Windows user account, which has permission to administer the Bamboo database.
For further information, please consult this MSDN article.
|
- Click 'Continue' to finish specifying your connection settings.
Screenshot 1: 'Setup JDBC Connection (MS SQL Server)' 
Connecting via a datasource
To connect Bamboo to a MS SQL Server, via a datasource,
- Configure a datasource in your application server (consult your application server documentation for details). For the syntax of the MS SQL Server URL to use, please see the MS SQL Server documentation
- At Step 2 of the Bamboo Setup Wizard, choose 'External Database' and select 'MSSQL' from the list.
- The 'Select Database Connection' screen will appear. Select 'Connect via a datasource (configured in the application server)'.
- The 'Setup Datasource Connection' screen will appear as shown in the screenshot below. In the 'JNDI name' field, type the JNDI name of your datasource, as configured in your application server.
If java:comp/env/jdbc/DataSourceName doesn't work, try jdbc/DataSourceName (and vice versa).
- Select the 'Overwrite existing data' checkbox if you wish Bamboo to overwrite any tables that already exist in the database.
 | Mixed mode Windows Authentication. On a typical MS SQL Server installation, 'Windows Authentication' mode is the default security mode. This means that if you try to connect to the database with a database user, MS SQL Server will throw the following error, "Login failed for user 'sa'. Reason: Not associated with a trusted SQL Server connection." To resolve this, you can either,
- Enable 'Mixed Mode Authentication'
- Log in with a Windows user account, which has permission to administer the Bamboo database.
For further information, please consult this MSDN article.
|
- Click 'Continue' to finish specifying your connection settings.
Screenshot 2: 'Setup Datasource Connection'

RELATED TOPICS
Bamboo Documentation Home
|