Administering the Sun Business Process Manager Database

Running the Scripts in Enterprise Designer

From Enterprise Designer, you can view, modify, and run the scripts that create or drop the monitoring and recovery database schema. First you must configure the database connection for the scripts.

Configuring the Database Connection

Before you can run the database scripts, you need to configure the database connection information in the Project Explorer. Configure the connection for the administrator user who has privileges to your database.

ProcedureTo configure the database connection

  1. In the Project Explorer, expand Sun BPM, and then expand Run Database Scripts.

  2. Right-click Run Database Scripts, click Check Out, and then click Check Out on the dialog box.

  3. Right-click Database Scripts and then click Properties.

  4. Enter the database configuration information described in Configuring the Database Connection.

  5. Click OK.

    Property

    Description 

    Database Type

    The database vendor and version you are using. 

    JDBC URL

    The URL to connect with the database. Enter one of the following: 

    • For Oracle: jdbc:SeeBeyond:oracle://<host>:<port>;SID=<SID>

    • For Sybase: jdbc:SeeBeyond:sybase://<host>:<port>

    • For SQL Server: jdbc:SeeBeyond:sqlserver://<host>:<port>;DatabaseName= <dbname>

    • For DB2: jdbc:SeeBeyond:db2://<host>:<port>;DatabaseName=<SID>;collectionId=JDBCPKG;packageName=JDBCPKG;embedded=true;createDefaultPackage=FALSE

      where <host> is the machine on which the database resides, <port> is the port number on which the database is listening, and <SID> and <dbname> are the name of the database.

    User

    The login ID of a database administrator. This user must be able to create users and assign permissions, as well as create and drop tables. 

    Password

    The password for the administrator user. 

Viewing and Modifying Database Scripts in Enterprise Designer

You can open the database scripts and view, modify, and run them within the Project Explorer. Consult your database administrator when making changes to the database scripts. Some of the changes you might need to make include:

ProcedureTo modify a database script

  1. In the Project Explorer, expand Sum BPM.

  2. Make sure Run Database Scripts is checked out, and then expand the folder.

  3. Under Database Scripts, right-click the script you want to modify, and then click Open.

  4. For Oracle 8.1.7 only, reduce the maximum key length for correlation keys from 4000 to 3166. The correlationvalue parameter belongs to the correlationengine and correlationbpinstance tables. The following code examples show the changes.

    create table bpm60 correlationengine ( correlationvalue varchar(3166) UNIQUE, applicationreference varchar(255), ...); ... create table bpm60.correlationbpinstance ( correlationvalue varchar(3166) UNIQUE, bpid varchar(50), ...);

  5. Make any other necessary changes to the script. Do not change any of the table or field names.

  6. To run the database script, right-click the script name and click Run. The database instance must be running in order to perform this step.

  7. To save your changes, right-click inside the script file and click Save, or close the file. You are prompted to save or discard your changes. To keep your changes, click Save; otherwise, click Discard.

Running the Database Scripts

Before running the database scripts, make sure you have a database instance running and have reviewed the information under Creating the Database Instance and Viewing and Modifying Database Scripts in Enterprise Designer. The connectivity information must also be configured for the scripts.

ProcedureTo create the database tables

  1. In the Project Explorer, expand Sum BPM, and then expand Run Database Scripts.

  2. Right-click the file associated with the appropriate database (Oracle Install, SQL Server Install, DB2 Install, or Sybase Install).

  3. Click Run.

ProcedureTo drop the database tables

  1. In the Project Explorer, expand Sum BPM, and then expand Run Database Scripts.

  2. Right-click the file associated with the appropriate database (Oracle Uninstall, SQL Server Uninstall, DB2 Uninstall, or Sybase Uninstall).

  3. Click Run.