Setting up Oracle

These instructions assume that you are using an Oracle database and guide you through the following tasks:

Note. When you create and access the database tables, be aware of the following issues:

Before following these instructions, you must have created one database with an Oracle SID of STAFFDB.

  1. To create the table called STAFF in the database STAFFDB:

    1. Open a new document in a text editor, copy and paste the following script, which creates the STAFF table, into the document, name the file stafftable.sql and save the file.
      DROP TABLE STAFF;
      CREATE TABLE STAFF (STAFFNUM CHAR(10), LASTCHANGE DATE, FIRSTNAME CHAR(30), LASTNAME CHAR(30));
      
    2. In a command window, move to the folder that contains stafftable.sql and enter the following command:
      sqlplus <uid>/<password>@STAFFDB @stafftable.sql
      

      Wait for the script to finish running. If you are running the script for the first time, the following message is displayed:

      ORA-00942: table or view does not exist
      Ignore this message. The message is displayed because the script attempts to remove an existing table called STAFF before it creates a new table, but if you have not run the script before, the script cannot find the existing table.
  2. Create an ODBC definition for the STAFFDB database with STAFFDB as the data source name (DSN). For instructions, see Enabling ODBC connections to the databases in the WebSphere Message Broker documentation.

Back to Setting up the database