} }

Document Conventions

The instructions provided in this section (as well as for the examples themselves) are for Windows. If you are using UNIX or Linux, substitute / for \ in path names.

MW_HOME  represents the central support directory for all Oracle WebLogic products installed on one machine; for example, c:\Oracle\Middleware.

WL_HOME  represents the top-level installation directory for the Oracle WebLogic Server. The default path is c:\Oracle\Middleware\wlserver_10.0. However, you are not required to install this directory under MW_HOME.

SAMPLES_HOME  represents the Oracle WebLogic Server examples home directory at WL_HOME\samples.

How Oracle WebLogic Server Uses PointBase

PointBase is a pure Java relational database management system (RDBMS) shipped with Oracle WebLogic Server. Its purpose is to allow you to run code examples with a functional database server. PointBase is for demonstration (that is, non-production) use only, and can be used only with Oracle WebLogic Server documentation and examples. See PointBase Licensing Restrictions. The Medical Records sample application application and most of the Oracle WebLogic examples use PointBase as a database server. For more information about PointBase, see the PointBase documentation installed with the Oracle WebLogic Server in the WL_HOME\common\eval\pointbase\docs directory.

Starting PointBase

PointBase starts automatically in a separate process (JVM) in the background when you start the Oracle WebLogic Server examples server or MedRec server. If you wish to run PointBase for a different domain, Oracle provides scripts that will start PointBase independently of these domains.

On Windows, run the script:

WL_HOME/common/eval/pointbase/tools/startPointBase.cmd

On UNIX, run the script:

WL_HOME\common\eval\pointbase\tools\startPointBase.sh

Note that weblogic.jar must be in your classpath when running PointBase. These scripts add weblogic.jar to your classpath.

These scripts reference a pointbase.ini file used for PointBase configuration.

Stopping PointBase

PointBase runs as a separate process from Oracle WebLogic Server. However, when you shut down the Oracle WebLogic Server examples or MedRec server, PointBase also stops.

To stop the examples or MedRec server and PointBase, see Stopping the Examples Server.

To stop PointBase if it was started manually in its own command window, perform one of the following steps:

The Samples Database

When you install Oracle WebLogic Server with the examples, the installation process creates a pre-built demonstration database in the WL_HOME\common\eval\pointbase\databases directory. If you need to build your own database, add these commands to the startWebLogic script in SAMPLES_HOME\domains\wl_server, and modify them for your environment:

set POINTBASE_HOME=%WL_HOME%\common\eval\pointbase
java utils.Schema "jdbc:pointbase:server://localhost/demo"
       com.pointbase.jdbc.jdbcUniversalDriver
       -u examples -p examples -verbose examples/common/ddl/demo.ddl

If you start PointBase 5.7 using an existing database created with PointBase 4.4, PointBase will automatically upgrade the database to version 5.7.

Opening the PointBase Console

The PointBase console has a graphical user interface that you can use to query the demo database and view results.

To open the PointBase Console:

  1. Start PointBase.
  2. If you are using Windows, run the WL_HOME/samples/domains/wl_server/bin/startPointBaseConsole.cmd script. (On Unix, run startPointBaseConsole.sh.) These scripts will start the PointBase Console.
  3. In the dialog box Connect to Database, enter these values (or make sure they are the default values):

    You can use any username/password combination to enter PointBase. However, you can make changes only if you enter the correct username/password for the schema you want to edit.

  4. Click OK. You should see the database URL in the window title bar.

    You can use the console to query and view database tables and columns. Perform queries either by choosing a standard query from a table's context menu, such as SELECT * FROM SYSUSERS, or by entering a query command in the top pane. The console displays the result set in the bottom pane.

PointBase Schemas

PointBase uses schemas to support multiple database connections. Schemas operate much the same way as multiple databases, and they are completely separate entities within the database they share. A schema can contain tables that have the same names as tables in other schemas. Users can be set up to have rights and permissions to specific schemas and not to other schemas.

Schemas fulfill the roles of multiple databases, with the added convenience of simplified administration. For more information, see the PointBase documentation.

This release of Oracle WebLogic Server uses one schema for the examples domain and another one for the medrec domain. The correct username and password will allow you to make changes to the respective schema. To edit a schema, open your PointBase console, open the DBA menu, and select 'Connect to a database.' Then fill in the username and password; the username and password for each schema is its name.

The schemas names are:

To view or edit any schema:

  1. Open the PointBase Console by following the steps in Opening the PointBase Console. If you wish to edit the schema, when you get to step 3 of those instructions enter the username and password for the schema you want to edit.
  2. The "Catalog View" is contained in the left-hand panel of your PointBase Console. In the Catalog View, expand the schema you want to edit.
  3. Continue to expand the nodes to view the tables, columns, and column data types.

Running a Code Example with PointBase

These steps describes how to run the jdbc.datasource.basic example using the PointBase demo database.

  1. Open a command window.
  2. Start the examples server using the startWebLogic.cmd script, located in SAMPLES_HOME\domains\wl_server.
  3. Open the Oracle WebLogic Server Administration Console by entering the following URL into your browser: http://localhost:7001/console.
  4. Sign in to the Oracle WebLogic Server Administration Console and select Services > JDBC > Data Sources from Domain Structure view in the left pane.
  5. In the table in the right pane of the console, verify that the data source named examples-dataSource-demoXAPool is deployed.
  6. Open a new command window and set the examples environment:
  7. Change to the example directory:

    cd SAMPLES_HOME\server\examples\src\examples\jdbc\datasource\basic

    where SAMPLES_HOME refers to the main Oracle WebLogic Server samples directory, such as c:\Oracle\Middleware\wlserver_10.3\samples.
  8. Compile the example: ant
  9. Run the example: ant run

    You should see output similar to this:

    Buildfile: build.xml
    run:
       [java] Making connection...
       [java] Table empdemo dropped.
       [java] Table empdemo created.
       [java] Number of rows inserted = 1
       [java] Number of rows deleted = 1
    BUILD SUCCESSFUL
    Total time: 5 seconds

PointBase Licensing Restrictions

PointBase is an all-Java DBMS product included in the Oracle WebLogic Server distribution solely in support of Oracle WebLogic Server evaluation, either in the form of custom trial applications or through packaged sample applications provided with Oracle WebLogic Server. Non-evaluation development and/or production use of the PointBase requires that a separate license be obtained by the end user directly from PointBase.

The PointBase license installed with Oracle WebLogic Server restricts use of PointBase to use with Oracle WebLogic Server. When you start PointBase, weblogic.jar must be in your classpath, although a Oracle WebLogic Server instance does not have to be running.

The PointBase license restricts the database size to 30 megabytes.


Copyright © 1996, 2009, Oracle and/or its affiliates. All Rights Reserved.