File/web/lib/external/pear-db/DB.php

Description

Database independent query interface

PHP versions 4 and 5

LICENSE: This source file is subject to version 3.0 of the PHP license that is available through the world-wide-web at the following URI: http://www.php.net/license/3_0.txt. If you did not receive a copy of the PHP License and are unable to obtain it through the web, please send a note to license@php.net so we can mail you a copy immediately.

Classes
Class Description
 class DB Database independent query interface
 class DB_Error DB_Error implements a class for reporting portable database error messages
 class DB_result This class implements a wrapper for a DB result set
 class DB_row PEAR DB Row Object
Includes
 require_once (DB_PEAR_PATH.'PEAR.php') (line 31)
Constants
DB_AUTOQUERY_INSERT = 1 (line 322)

The type of query to create with the automatic query building methods.

DB_AUTOQUERY_UPDATE = 2 (line 323)

The type of query to create with the automatic query building methods.

DB_BINMODE_CONVERT = 3 (line 244)

Converts the data to hex format before returning it

The different ways of returning binary data from queries. For example the string "123" would become "313233".

DB_BINMODE_PASSTHRU = 1 (line 232)

Sends the fetched data straight through to output

The different ways of returning binary data from queries.

DB_BINMODE_RETURN = 2 (line 237)

Lets you return data as usual

The different ways of returning binary data from queries.

DB_ERROR = -1 (line 54)

Unkown error

One of PEAR DB's portable error codes.

DB_ERROR_ACCESS_VIOLATION = -26 (line 174)

The present user has inadequate permissions to perform the task requestd

One of PEAR DB's portable error codes.

DB_ERROR_ALREADY_EXISTS = -5 (line 74)

Tried to create a duplicate object

One of PEAR DB's portable error codes.

DB_ERROR_CANNOT_CREATE = -15 (line 124)

Could not create the object requested

One of PEAR DB's portable error codes.

DB_ERROR_CANNOT_DROP = -17 (line 129)

Could not drop the database requested because it does not exist

One of PEAR DB's portable error codes.

DB_ERROR_CONNECT_FAILED = -24 (line 164)

Could not connect to the database

One of PEAR DB's portable error codes.

DB_ERROR_CONSTRAINT = -3 (line 64)

Tried to insert a duplicate value into a primary or unique index

One of PEAR DB's portable error codes.

DB_ERROR_CONSTRAINT_NOT_NULL = -29 (line 184)

Tried to insert a null value into a column that doesn't allow nulls

One of PEAR DB's portable error codes.

DB_ERROR_DIVZERO = -13 (line 114)

Attempt to divide something by zero

One of PEAR DB's portable error codes.

DB_ERROR_EXTENSION_NOT_FOUND = -25 (line 169)

The PHP extension needed for this DBMS could not be found

One of PEAR DB's portable error codes.

DB_ERROR_INVALID = -8 (line 89)

A literal submitted did not match the data type expected

One of PEAR DB's portable error codes.

DB_ERROR_INVALID_DATE = -12 (line 109)

A literal date submitted did not match the data type expected

One of PEAR DB's portable error codes.

DB_ERROR_INVALID_DSN = -23 (line 159)

The DSN submitted has problems

One of PEAR DB's portable error codes.

DB_ERROR_INVALID_NUMBER = -11 (line 104)

A literal number submitted did not match the data type expected

One of PEAR DB's portable error codes.

DB_ERROR_MISMATCH = -7 (line 84)

The number of parameters does not match the number of placeholders

One of PEAR DB's portable error codes.

DB_ERROR_NEED_MORE_DATA = -20 (line 144)

The data submitted to the method was inappropriate

One of PEAR DB's portable error codes.

DB_ERROR_NODBSELECTED = -14 (line 119)

A database needs to be selected

One of PEAR DB's portable error codes.

DB_ERROR_NOSUCHDB = -27 (line 179)

The database requested does not exist

One of PEAR DB's portable error codes.

DB_ERROR_NOSUCHFIELD = -19 (line 139)

An identifier in the query refers to a non-existant column

One of PEAR DB's portable error codes.

DB_ERROR_NOSUCHTABLE = -18 (line 134)

An identifier in the query refers to a non-existant table

One of PEAR DB's portable error codes.

DB_ERROR_NOT_CAPABLE = -9 (line 94)

The current DBMS does not support the action you attempted

One of PEAR DB's portable error codes.

DB_ERROR_NOT_FOUND = -4 (line 69)

An identifier in the query refers to a non-existant object

One of PEAR DB's portable error codes.

DB_ERROR_NOT_LOCKED = -21 (line 149)

The attempt to lock the table failed

One of PEAR DB's portable error codes.

DB_ERROR_SYNTAX = -2 (line 59)

Syntax error

One of PEAR DB's portable error codes.

DB_ERROR_TRUNCATED = -10 (line 99)

A literal submitted was too long so the end of it was removed

One of PEAR DB's portable error codes.

DB_ERROR_UNSUPPORTED = -6 (line 79)

The current driver does not support the action you attempted

One of PEAR DB's portable error codes.

DB_ERROR_VALUE_COUNT_ON_ROW = -22 (line 154)

The number of columns doesn't match the number of values

One of PEAR DB's portable error codes.

DB_FETCHMODE_ASSOC = 2 (line 271)

Column data indexed by column names

Fetch Modes.

DB_FETCHMODE_DEFAULT = 0 (line 261)

Indicates the current default fetch mode should be used

Fetch Modes.

DB_FETCHMODE_FLIPPED = 4 (line 285)

For multi-dimensional results, make the column name the first level of the array and put the row number in the second level of the array

Fetch Modes. This is flipped from the normal behavior, which puts the row numbers in the first level of the array and the column names in the second level.

DB_FETCHMODE_OBJECT = 3 (line 276)

Column data as object properties

Fetch Modes.

DB_FETCHMODE_ORDERED = 1 (line 266)

Column data indexed by numbers, ordered from 0 and up

Fetch Modes.

DB_GETMODE_ASSOC = DB_FETCHMODE_ASSOC (line 292)

Old fetch modes. Left here for compatibility.

DB_GETMODE_FLIPPED = DB_FETCHMODE_FLIPPED (line 293)

Old fetch modes. Left here for compatibility.

DB_GETMODE_ORDERED = DB_FETCHMODE_ORDERED (line 291)

Old fetch modes. Left here for compatibility.

DB_OK = 1 (line 49)

The code returned by many methods upon success

One of PEAR DB's portable error codes.

DB_PARAM_MISC = 3 (line 217)

Indicates a misc (!) placeholder was used

Identifiers for the placeholders used in prepared statements. The value should not be quoted or escaped.

DB_PARAM_OPAQUE = 2 (line 210)

Indicates an opaque (&) placeholder was used

Identifiers for the placeholders used in prepared statements. The value presented is a file name. Extract the contents of that file and place them in this column.

DB_PARAM_SCALAR = 1 (line 202)

Indicates a scalar (?) placeholder was used

Identifiers for the placeholders used in prepared statements. Quote and escape the value as necessary.

DB_PEAR_PATH = $apps_path['libs'].'/external/pear-db/' (line 30)

Obtain the PEAR class so it can be extended from

DB_PORTABILITY_ALL = 63 (line 391)

Turn on all portability features

Portability Modes.

Bitwised constants, so they can be combined using | and removed using ^.

DB_PORTABILITY_DELETE_COUNT = 4 (line 362)

Force reporting the number of rows deleted

Portability Modes.

Bitwised constants, so they can be combined using | and removed using ^.

DB_PORTABILITY_ERRORS = 16 (line 380)

Makes certain error messages in certain drivers compatible with those from other DBMS's

Portability Modes.

Bitwised constants, so they can be combined using | and removed using ^.

  • mysql, mysqli: change unique/primary key constraints DB_ERROR_ALREADY_EXISTS -> DB_ERROR_CONSTRAINT
  • odbc(access): MS's ODBC driver reports 'no such field' as code 07001, which means 'too few parameters.' When this option is on that code gets mapped to DB_ERROR_NOSUCHFIELD.

DB_PORTABILITY_LOWERCASE = 1 (line 352)

Convert names of tables and fields to lower case

Portability Modes.

Bitwised constants, so they can be combined using | and removed using ^.

when using the get*(), fetch*() and tableInfo() methods

DB_PORTABILITY_NONE = 0 (line 346)

Turn off all portability features

Portability Modes.

Bitwised constants, so they can be combined using | and removed using ^.

DB_PORTABILITY_NULL_TO_EMPTY = 32 (line 386)

Convert null values to empty strings in data output by

Portability Modes.

Bitwised constants, so they can be combined using | and removed using ^.

get*() and fetch*()

DB_PORTABILITY_NUMROWS = 8 (line 367)

Enable hack that makes numRows() work in Oracle

Portability Modes.

Bitwised constants, so they can be combined using | and removed using ^.

DB_PORTABILITY_RTRIM = 2 (line 357)

Right trim the data output by get*() and fetch*()

Portability Modes.

Bitwised constants, so they can be combined using | and removed using ^.

DB_TABLEINFO_FULL = 3 (line 314)

The type of information to return from the tableInfo() method.

Bitwised constants, so they can be combined using | and removed using ^.

DB_TABLEINFO_ORDER = 1 (line 312)

The type of information to return from the tableInfo() method.

Bitwised constants, so they can be combined using | and removed using ^.

DB_TABLEINFO_ORDERTABLE = 2 (line 313)

The type of information to return from the tableInfo() method.

Bitwised constants, so they can be combined using | and removed using ^.

Documentation generated on Wed, 09 Feb 2011 08:59:11 +0700 by phpDocumentor 1.4.2