DBM is a class of the SAP::DBTech::dbm module. An instance of this class corresponds to a connection to a DBM server.
Syntax
$session = new DBM ($database_computer, $database_name, $dependent_path, $user_info);
Parameters |
Description |
---|---|
$database_computer |
Name of the computer to which you want to connect The default value is the local computer. |
$database_name |
Name of the database that is to be connected. This information is optional. |
$dependent_path |
Installation path of the database software (See also: Glossary, Directory) This information is optional. |
$user_info |
A string in the format <dbm_operator>,<dbm_operator_password> The specified DBM operator connects to the program DBM server. This information is optional. |
If there are multiple installations of the database software on your computer, you can use the $database_name and $dependent_path parameters to control which version of the DBM server program is started.
Case 1 – You want to create a new database with the latest software installation or you want to display information about the existing databases and software versions.
Do not specify $database_name or $dependent_path.
The system then starts the DBM server of the software installation that has the highest version number.
Case 2 – You want to administer a specific database.
Specify the $database_name but not the $dependent_path.
The system then starts the DBM Server belonging to the specified database.
Case 3 – You want to create a new database with a specific software version.
Specify the $dependent_path but not the $database_name.
The system then starts the DBM server of the specified software installation.
You create a $session connection object for the DEMODB database on the local computer:
$session = sdb.dbm.DBM ('', 'DEMODB', '', 'OLEG,MONDAY');