Entering content frame

Background documentation DBPOOL Locate the document in its SAP Library structure

This section describes the commands of the JDBC Connector Service. They are added to the shell environment by executing ADD DBPOOL on the command line.

CLOSE_CONN

Syntax

CLOSE_CONN <dataSourceName><connectionID>

Arguments

 

<dataSourceName>

The name of the DataSource used to obtain the connection

<connectionID>

The identifier of the connection you want to close. You can get the connection ID using the LIST_CONN command.

Description

Closes a particular connection specified by the DataSource that provided it and its ID.

 

DB_INIT

Syntax

DB_INIT <fileName>

Arguments

 

<fileName>

The path to the XML file that describes properties for database initialization. The format of this file is defined in db_init.dtd.

Description

Initializes a database with the SQL statements in the XML file using the DataSource that is associated to these statements

 

DEFINE_JDBC_DRIVER

Syntax

DEFINE_JDBC_DRIVER <driverName>

Arguments

 

<driverName>

The name of the library that contains the classes of the driver

Description

Registers a JDBC driver that has been deployed on the server as a library without using JDBC Connector Service

 

DEPLOY_ALIASES

Syntax

DEPLOY_ALIASES <fileName>

Arguments

 

<fileName>

The path to the XML file that contains the definitions of the aliases for a relevant DataSource. The format of this XML file is defined in data-source-aliases.dtd

Description

Defines aliases for a previously deployed DataSource

 

DEPLOY_JDBC_DRIVER

Syntax

DEPLOY_JDBC_DRIVER <driverName> <fileNames>

Arguments

 

<driverName>

An arbitrary name of the driver that you deploy

<fileNames>

The names of one or more archive files that contain the classes of the driver, and the paths to them. If you specify more than one archive file, separate the paths to the files with a semicolon.

Description

Registers a JDBC driver by the specified name and the archive file of the driver

Example

DEPLOY_JDBC_DRIVER mySAPDriver C:\sapdbc.jar

 

DESTROY_CONN

Syntax

DESTROY_CONN <dataSourceName><connectionID>

Arguments

 

<dataSourceName>

The name of the DataSource used to obtain the connection

<connectionID>

The identifier of the connection you want to destroy. You can get the connection ID using the LIST_CONN command.

Description

Destroys a connection specified by the DataSource that created it and its ID.

 

EXECUTE_INIT_STATEMENTS

Syntax

EXECUTE_INIT_STATEMENTS <dataSourceName>

Arguments

 

<dataSourceName>

The name of the DataSource object used to execute the SQL statements

Description

Executes the SQL statements associated to the specified DataSource in order to initialize a database

 

GET_DRIVERS

Syntax

GET_DRIVERS

Description

Returns a list of all deployed and defined JDBC drivers on J2EE Engine

 

GET_DS

Syntax

GET_DS

Description

Returns a list of the DataSource objects associated to the applications currently running on J2EE Engine

 

GET_DS_PROPS

Syntax

GET_DS_PROPS <DataSource_name>

Arguments

 

<DataSource_name>

The name of the DataSource whose properties you want to view

Description

Provides a list of the properties and their values for the specified DataSource

 

GET_FREE_CONN

Syntax

GET_FREE_CONN <dataSourceName>

Arguments

 

<dataSourceName>

The name of the DataSource for which the command retrieves free connections

Description

Returns the number of free physical connections created using the specified DataSource

 

GET_INIT_STATEMENTS

Syntax

GET_INIT_STATEMENTS <parameters>

Arguments

 

<dataSourceName>

The name of a particular DataSource; the command lists only the SQL statements associated to this DataSource.

-all

The command lists the SQL statements associated to each DataSource object.

Description

Lists the SQL statements for database initialization either for a particular DataSource or for all existing DataSource objects

 

GET_USED_CONN

Syntax

GET_USED_CONN <dataSourceName>

Arguments

 

<dataSourceName>

The name of the DataSource for which the command retrieves the number of used connections

Description

Returns the number of used physical connections created using the specified DataSource

 

LIST_CONN

Syntax

LIST_CONN <dataSourceName>

Arguments

 

<dataSourceName>

The name of the DataSource for which the command retrieves all connections

Description

Returns a list of the IDs of both free and used physical connections created using the specified DataSource, and the IDs of the corresponding ConnectionHandle objects

 

MAKE_DATA_SOURCE

Syntax

MAKE_DATA_SOURCE <fileName>

Arguments

 

<fileName>

The path to the XML file that describes the properties of the DataSource you want to create. The format of this file is defined in data-sources.dtd.

Description

Creates a DataSource with the properties from the specified XML file

 

REMOVE_DATA_SOURCE

Syntax

REMOVE_DATA_SOURCE <dataSourceName>

Arguments

 

<dataSourceName>

The name of a DataSource to be removed

Description

Destroys a DataSource unless it is the only one associated to the relevant application

 

REMOVE_INIT_STATEMENTS

Syntax

REMOVE_INIT_STATEMENTS <dataSourceName>

Arguments

 

<dataSourceName>

The name of a DataSource whose associated initialization statements are removed

Description

Disassociates and removes the database initialization statements for the specified DataSource

 

TEST_DS

Syntax

TEST_DS <dataSourceName> <sqlStatement>

Arguments

 

<dataSourceName>

The name of the DataSource that you want to test

<sqlStatement>

A string representing an SQL statement, which is used to test if the DataSource actually provides a connection to the database

Description

Tests whether the specified DataSource functions properly provide connection to the database you are using

 

UNDEFINE_JDBC_DRIVER

Syntax

UNDEFINE_JDBC_DRIVER <driverName>

Arguments

 

<driverName>

The name of the library that contains the driver

Description

Removes a library that was defined as a JDBC driver from the list of registered drivers

 

UNDEPLOY_JDBC_DRIVER

Syntax

UNDEPLOY_JDBC_DRIVER <driverName>

Arguments

 

<driverName>

The name of the JDBC driver that you want to remove

Description

Completely removes a JDBC driver from J2EE Engine

 

 

Leaving content frame