dbdefs.inc.php

Default Login data and configuration options.

Constants

OCIDB_HOST

OCIDB_HOST

The TNS name of the target database to connect to.

If running locally on the database server you may leave that string empty.

OCIDB_USER

OCIDB_USER

The Database username used for connecting.

OCIDB_PASS

OCIDB_PASS

The password used for connecting.

OCIAPPNAME

OCIAPPNAME

Enter the name of your application here.

Used when printing out error messages and also used to register this name to Oracle when DB_REGISTER is set to 1.

DB_REGISTER

DB_REGISTER

Set the following define to 0 if you do not want auto-register of OCIAPPNAME.

DB_SET_NUMERIC

DB_SET_NUMERIC

Grouping character autoset.

Set the following define to 0 if you do not want to auto-set the decimal and grouping characters (see below).

DB_NUM_DECIMAL

DB_NUM_DECIMAL

Define here what you are using as grouping character and decimal character.

Germans usually use DECIMAL=, | GROUPING =. in opposite of english/american which seems to be using DECIMAL=. | GROUPING=, and if you are using something completly different, please drop me a short mail and tell me what you use, I always love to learn :)

DB_NUM_GROUPING

DB_NUM_GROUPING

DB_ERRORMODE

DB_ERRORMODE

Modify default error handling mode if you wish.

Default is spfalz\db_oci8::DBOF_SHOW_NO_ERRORS if you omit this parameter.

DB_DEFAULT_PREFETCH

DB_DEFAULT_PREFETCH

You may set a default prefetch value with this define.

This is a simple solution to have a higher prefetch value defined as default for all your queries instead of calling setPrefetch() everytime.

OCIDB_SENTMAILONERROR

OCIDB_SENTMAILONERROR

Set this define to 1 if you want auto-emails to be sent whenever an error occures.

Default is 0 (disabled)

OCIDB_USE_PCONNECT

OCIDB_USE_PCONNECT

Set this define to 1 if you want to use persistant connections as default connection.

Default is 0, which means that OCIlogon is used instead. (new connections).

OCIDB_CONNECT_RETRIES

OCIDB_CONNECT_RETRIES

Set amount of retries in case of a connection failure.

Whenever the connection fails and you have defined a value which is greater than 1 the class sleeps for two seconds and retry connection attempt. If you do not define any value here the class uses the default of 1 connection attempt without any sleep, this is the behavour in all previous versions.

OCIDB_CHARSET

OCIDB_CHARSET

Setup a default characterset to be used during the connection (Only for Oracle >= 9.2 and PHP 5.1.2+).

If this define is not set the NLS_LANG environment variable value is used. You can also override this when using the connect() method.