Class ADODB_postgres64

Description

Connection object. For connecting to databases, and executing queries.

Located in /3rd/adodb/drivers/adodb-postgres64.inc.php (line 57)

ADOConnection
   |
   --ADODB_postgres64
Direct descendents
Class Description
 class ADODB_netezza Connection object. For connecting to databases, and executing queries.
 class ADODB_postgres7 Connection object. For connecting to databases, and executing queries.
Variable Summary
Method Summary
 ADODB_postgres64 ADODB_postgres64 ()
 void BeginTrans ()
 void BlobDecode ( $blob, [ $maxsize = false], [ $hastrans = true])
 void BlobEncode ( $blob)
 void CharMax ()
 void CommitTrans ([ $ok = true])
 void ErrorMsg ()
 void ErrorNo ()
 void GuessOID ( $oid)
 void IfNull ( $field,  $ifNull)
 void &MetaColumns ( $table, [ $normalize = true])
 void &MetaIndexes ( $table, [ $primary = FALSE])
 void &MetaTables ([ $ttype = false], [ $showSchema = false], [ $mask = false])
 void OffsetDate ( $dayFraction, [ $date = false])
 void pg_insert_id ( $tablename,  $fieldname)
 void RollbackTrans ()
 void RowLock ( $tables,  $where, [ $flds = '1 as ignore'])
 void ServerInfo ()
 void SQLDate ( $fmt, [ $col = false])
 void TextMax ()
 void UpdateBlob ( $table,  $column,  $val,  $where, [ $blobtype = 'BLOB'])
 void UpdateBlobFile ( $table,  $column,  $path,  $where, [ $blobtype = 'BLOB'])
 void _affectedrows ()
 void _close ()
 void _connect ( $str, [ $user = ''], [ $pwd = ''], [ $db = ''], [ $ctype = 0])
 void _insertid ( $table,  $column)
 void _nconnect ( $argHostname,  $argUsername,  $argPassword,  $argDatabaseName)
 void _pconnect ( $str, [ $user = ''], [ $pwd = ''], [ $db = ''])
 void _query ( $sql,  $inputarr)
Variables
mixed $autoRollback = true (line 105)

Redefinition of:
ADOConnection::$autoRollback

Redefined in descendants as:
mixed $blobEncodeType = 'C' (line 73)

Redefinition of:
ADOConnection::$blobEncodeType

Redefined in descendants as:
mixed $concat_operator = '||' (line 62)

Redefinition of:
ADOConnection::$concat_operator

Redefined in descendants as:
mixed $databaseType = 'postgres64' (line 58)

Redefinition of:
ADOConnection::$databaseType

Redefined in descendants as:
mixed $dataProvider = 'postgres' (line 59)

Redefinition of:
ADOConnection::$dataProvider

Redefined in descendants as:
mixed $disableBlobs = false (line 109)
mixed $false = 'FALSE' (line 95)

Redefinition of:
ADOConnection::$false

Redefined in descendants as:
mixed $fmtDate = "'Y-m-d'" (line 96)

Redefinition of:
ADOConnection::$fmtDate

Redefined in descendants as:
mixed $fmtTimeStamp = "'Y-m-d G:i:s'" (line 97)

Redefinition of:
ADOConnection::$fmtTimeStamp

Redefined in descendants as:
mixed $hasAffectedRows = true (line 91)

Redefinition of:
ADOConnection::$hasAffectedRows

Redefined in descendants as:
mixed $hasGenID = true (line 99)

Redefinition of:
ADOConnection::$hasGenID
mixed $hasInsertID = true (line 60)

Redefinition of:
ADOConnection::$hasInsertID

Redefined in descendants as:
mixed $hasLimit = false (line 92)

Redefinition of:
ADOConnection::$hasLimit

Redefined in descendants as:
mixed $hasMoveFirst = true (line 98)

Redefinition of:
ADOConnection::$hasMoveFirst
mixed $isoDates = true (line 70)

Redefinition of:
ADOConnection::$isoDates

Redefined in descendants as:
mixed $metaColumnsSQL = "SELECT a.attname,t.typname,a.attlen,a.atttypmod,a.attnotnull,a.atthasdef,a.attnum
FROM pg_class c, pg_attribute a,pg_type t
WHERE relkind in ('r','v') AND (c.relname='%s' or c.relname = lower('%s')) and a.attname not like '....%%'
AND a.attnum > 0 AND a.atttypid = t.oid AND a.attrelid = c.oid ORDER BY a.attnum"
(line 74)

Redefined in descendants as:
mixed $metaColumnsSQL1 = "SELECT a.attname, t.typname, a.attlen, a.atttypmod, a.attnotnull, a.atthasdef, a.attnum
FROM pg_class c, pg_attribute a, pg_type t, pg_namespace n
WHERE relkind in ('r','v') AND (c.relname='%s' or c.relname = lower('%s'))
and c.relnamespace=n.oid and n.nspname='%s'
and a.attname not like '....%%' AND a.attnum > 0
AND a.atttypid = t.oid AND a.attrelid = c.oid ORDER BY a.attnum"
(line 80)

Redefined in descendants as:
mixed $metaDatabasesSQL = "select datname from pg_database where datname not in ('template0','template1') order by 1" (line 63)

Redefinition of:
ADOConnection::$metaDatabasesSQL

Redefined in descendants as:
mixed $metaDefaultsSQL = "SELECT d.adnum as num, d.adsrc as def from pg_attrdef d, pg_class c where d.adrelid=c.oid and c.relname='%s' order by d.adnum" (line 103)
mixed $metaKeySQL = "SELECT ic.relname AS index_name, a.attname AS column_name,i.indisunique AS unique_key, i.indisprimary AS primary_key
FROM pg_class bc, pg_class ic, pg_index i, pg_attribute a WHERE bc.oid = i.indrelid AND ic.oid = i.indexrelid AND (i.indkey[0] = a.attnum OR i.indkey[1] = a.attnum OR i.indkey[2] = a.attnum OR i.indkey[3] = a.attnum OR i.indkey[4] = a.attnum OR i.indkey[5] = a.attnum OR i.indkey[6] = a.attnum OR i.indkey[7] = a.attnum) AND a.attrelid = bc.oid AND bc.relname = '%s'"
(line 88)

Redefined in descendants as:
mixed $metaTablesSQL = "select tablename,'T' from pg_tables where tablename not like 'pg\_%'
and tablename not in ('sql_features', 'sql_implementation_info', 'sql_languages',
'sql_packages', 'sql_sizing', 'sql_sizing_profiles')
union
select viewname,'V' from pg_views where viewname not like 'pg\_%'"
(line 64)

Redefinition of:
ADOConnection::$metaTablesSQL

Redefined in descendants as:
mixed $random = 'random()' (line 104)

Redefinition of:
ADOConnection::$random

Redefined in descendants as:
mixed $sysDate = "CURRENT_DATE" (line 71)

Redefinition of:
ADOConnection::$sysDate

Redefined in descendants as:
mixed $sysTimeStamp = "CURRENT_TIMESTAMP" (line 72)

Redefinition of:
ADOConnection::$sysTimeStamp

Redefined in descendants as:
mixed $true = 'TRUE' (line 94)

Redefinition of:
ADOConnection::$true

Redefined in descendants as:
mixed $_bindInputArray = false (line 108)

Redefinition of:
ADOConnection::$_bindInputArray
mixed $_dropSeqSQL = "DROP SEQUENCE %s" (line 102)
mixed $_genIDSQL = "SELECT NEXTVAL('%s')" (line 100)
mixed $_genSeqSQL = "CREATE SEQUENCE %s START %s" (line 101)
mixed $_resultid = false (line 61)

Redefined in descendants as:

Inherited Variables

Inherited from ADOConnection

ADOConnection::$ansiOuter
ADOConnection::$arrayClass
ADOConnection::$autoCommit
ADOConnection::$cacheSecs
ADOConnection::$charSet
ADOConnection::$database
ADOConnection::$debug
ADOConnection::$emptyDate
ADOConnection::$emptyTimeStamp
ADOConnection::$fetchMode
ADOConnection::$fnCacheExecute
ADOConnection::$fnExecute
ADOConnection::$genID
ADOConnection::$hasTop
ADOConnection::$hasTransactions
ADOConnection::$host
ADOConnection::$lastInsID
ADOConnection::$leftOuter
ADOConnection::$length
ADOConnection::$maxblobsize
ADOConnection::$nameQuote
ADOConnection::$noNullStrings
ADOConnection::$numCacheHits
ADOConnection::$numCacheMisses
ADOConnection::$pageExecuteCountRows
ADOConnection::$password
ADOConnection::$poorAffectedRows
ADOConnection::$raiseErrorFn
ADOConnection::$readOnly
ADOConnection::$replaceQuote
ADOConnection::$rightOuter
ADOConnection::$rsPrefix
ADOConnection::$substr
ADOConnection::$transCnt
ADOConnection::$transOff
ADOConnection::$uniqueOrderBy
ADOConnection::$uniqueSort
ADOConnection::$upperCase
ADOConnection::$user
ADOConnection::$_affected
ADOConnection::$_connectionID
ADOConnection::$_errorCode
ADOConnection::$_errorMsg
ADOConnection::$_evalAll
ADOConnection::$_isPersistentConnection
ADOConnection::$_logsql
ADOConnection::$_oldRaiseFn
ADOConnection::$_queryID
ADOConnection::$_transOK
Methods
Constructor ADODB_postgres64 (line 119)
ADODB_postgres64 ADODB_postgres64 ()
BeginTrans (line 173)
void BeginTrans ()

Redefinition of:
ADOConnection::BeginTrans()
Begin a Transaction. Must be followed by CommitTrans() or RollbackTrans().
BlobDecode (line 381)
void BlobDecode ( $blob, [ $maxsize = false], [ $hastrans = true])
  • $blob
  • $maxsize
  • $hastrans

Redefinition of:
ADOConnection::BlobDecode()
BlobEncode (line 405)
void BlobEncode ( $blob)
  • $blob

Redefinition of:
ADOConnection::BlobEncode()
CharMax (line 802)
void CharMax ()
CommitTrans (line 187)
void CommitTrans ([ $ok = true])
  • $ok

Redefinition of:
ADOConnection::CommitTrans()
If database does not support transactions, always return true as data always commited
ErrorMsg (line 757)
void ErrorMsg ()

Redefinition of:
ADOConnection::ErrorMsg()
ErrorNo (line 776)
void ErrorNo ()

Redefinition of:
ADOConnection::ErrorNo()
GuessOID (line 363)
void GuessOID ( $oid)
  • $oid
IfNull (line 134)
void IfNull ( $field,  $ifNull)
  • $field
  • $ifNull

Redefinition of:
ADOConnection::IfNull()
MetaColumns (line 437)
void &MetaColumns ( $table, [ $normalize = true])
  • $table
  • $normalize

Redefinition of:
ADOConnection::MetaColumns()
List columns in a database as an array of ADOFieldObjects.

Redefined in descendants as:
MetaIndexes (line 550)
void &MetaIndexes ( $table, [ $primary = FALSE])
  • $table
  • $primary

Redefinition of:
ADOConnection::MetaIndexes()
List indexes on a table as an array.
MetaTables (line 204)
void &MetaTables ([ $ttype = false], [ $showSchema = false], [ $mask = false])
  • $ttype
  • $showSchema
  • $mask

Redefinition of:
ADOConnection::MetaTables()
OffsetDate (line 428)
void OffsetDate ( $dayFraction, [ $date = false])
  • $dayFraction
  • $date

Redefinition of:
ADOConnection::OffsetDate()
pg_insert_id (line 140)
void pg_insert_id ( $tablename,  $fieldname)
  • $tablename
  • $fieldname
RollbackTrans (line 197)
void RollbackTrans ()

Redefinition of:
ADOConnection::RollbackTrans()
If database does not support transactions, rollbacks always fail, so return false
RowLock (line 180)
void RowLock ( $tables,  $where, [ $flds = '1 as ignore'])
  • $tables
  • $where
  • $flds

Redefinition of:
ADOConnection::RowLock()
Lock a row, will escalate and lock the table if row locking not supported will normally free the lock at the end of the transaction
ServerInfo (line 124)
void ServerInfo ()

Redefinition of:
ADOConnection::ServerInfo()
SQLDate (line 257)
void SQLDate ( $fmt, [ $col = false])
  • $fmt
  • $col

Redefinition of:
ADOConnection::SQLDate()
TextMax (line 810)
void TextMax ()
UpdateBlob (line 418)
void UpdateBlob ( $table,  $column,  $val,  $where, [ $blobtype = 'BLOB'])
  • $table
  • $column
  • $val
  • $where
  • $blobtype

Redefinition of:
ADOConnection::UpdateBlob()
Update a blob column, given a where clause. There are more sophisticated blob handling functions that we could have implemented, but all require a very complex API. Instead we have chosen something that is extremely simple to understand and use.
UpdateBlobFile (line 340)
void UpdateBlobFile ( $table,  $column,  $path,  $where, [ $blobtype = 'BLOB'])
  • $table
  • $column
  • $path
  • $where
  • $blobtype

Redefinition of:
ADOConnection::UpdateBlobFile()
Usage: UpdateBlob('TABLE', 'COLUMN', '/path/to/file', 'ID=1');
_affectedrows (line 165)
void _affectedrows ()
_close (line 786)
void _close ()
_connect (line 616)
void _connect ( $str, [ $user = ''], [ $pwd = ''], [ $db = ''], [ $ctype = 0])
  • $str
  • $user
  • $pwd
  • $db
  • $ctype
_insertid (line 155)
void _insertid ( $table,  $column)
  • $table
  • $column
_nconnect (line 660)
void _nconnect ( $argHostname,  $argUsername,  $argPassword,  $argDatabaseName)
  • $argHostname
  • $argUsername
  • $argPassword
  • $argDatabaseName

Redefinition of:
ADOConnection::_nconnect()
_pconnect (line 670)
void _pconnect ( $str, [ $user = ''], [ $pwd = ''], [ $db = ''])
  • $str
  • $user
  • $pwd
  • $db
_query (line 677)
void _query ( $sql,  $inputarr)
  • $sql
  • $inputarr

Inherited Methods

Inherited From ADOConnection

 ADOConnection::ADOConnection()
 ADOConnection::addq()
 ADOConnection::Affected_Rows()
 ADOConnection::AutoExecute()
 ADOConnection::BeginTrans()
 ADOConnection::BlobDecode()
 ADOConnection::BlobEncode()
 ADOConnection::CacheExecute()
 ADOConnection::CacheFlush()
 ADOConnection::CacheGetAll()
 ADOConnection::CacheGetArray()
 ADOConnection::CacheGetAssoc()
 ADOConnection::CacheGetCol()
 ADOConnection::CacheGetOne()
 ADOConnection::CacheGetRow()
 ADOConnection::CachePageExecute()
 ADOConnection::CacheSelectLimit()
 ADOConnection::Close()
 ADOConnection::CommitLock()
 ADOConnection::CommitTrans()
 ADOConnection::CompleteTrans()
 ADOConnection::Concat()
 ADOConnection::Connect()
 ADOConnection::CreateSequence()
 ADOConnection::DBDate()
 ADOConnection::DBTimeStamp()
 ADOConnection::Disconnect()
 ADOConnection::DropSequence()
 ADOConnection::ErrorMsg()
 ADOConnection::ErrorNative()
 ADOConnection::ErrorNo()
 ADOConnection::escape()
 ADOConnection::Execute()
 ADOConnection::FailTrans()
 ADOConnection::GenID()
 ADOConnection::GetAll()
 ADOConnection::GetArray()
 ADOConnection::GetAssoc()
 ADOConnection::GetCharSet()
 ADOConnection::GetCol()
 ADOConnection::GetInsertSQL()
 ADOConnection::GetOne()
 ADOConnection::GetRow()
 ADOConnection::GetUpdateSQL()
 ADOConnection::HasFailedTrans()
 ADOConnection::IfNull()
 ADOConnection::InParameter()
 ADOConnection::Insert_ID()
 ADOConnection::IsConnected()
 ADOConnection::LimitQuery()
 ADOConnection::LogSQL()
 ADOConnection::MetaColumnNames()
 ADOConnection::MetaColumns()
 ADOConnection::MetaDatabases()
 ADOConnection::MetaError()
 ADOConnection::MetaErrorMsg()
 ADOConnection::MetaForeignKeys()
 ADOConnection::MetaIndexes()
 ADOConnection::MetaPrimaryKeys()
 ADOConnection::MetaTables()
 ADOConnection::MetaType()
 ADOConnection::NConnect()
 ADOConnection::nextId()
 ADOConnection::OffsetDate()
 ADOConnection::outp()
 ADOConnection::OutParameter()
 ADOConnection::PageExecute()
 ADOConnection::Param()
 ADOConnection::Parameter()
 ADOConnection::PConnect()
 ADOConnection::PO_Insert_ID()
 ADOConnection::Prepare()
 ADOConnection::PrepareSP()
 ADOConnection::q()
 ADOConnection::QMagic()
 ADOConnection::qstr()
 ADOConnection::Query()
 ADOConnection::Quote()
 ADOConnection::Replace()
 ADOConnection::RollbackLock()
 ADOConnection::RollbackTrans()
 ADOConnection::RowLock()
 ADOConnection::SelectDB()
 ADOConnection::SelectLimit()
 ADOConnection::SerializableRS()
 ADOConnection::ServerInfo()
 ADOConnection::SetCharSet()
 ADOConnection::SetDateLocale()
 ADOConnection::SetFetchMode()
 ADOConnection::SQLDate()
 ADOConnection::StartTrans()
 ADOConnection::Time()
 ADOConnection::UnixDate()
 ADOConnection::UnixTimeStamp()
 ADOConnection::UpdateBlob()
 ADOConnection::UpdateBlobFile()
 ADOConnection::UpdateClob()
 ADOConnection::UserDate()
 ADOConnection::UserTimeStamp()
 ADOConnection::Version()
 ADOConnection::_Execute()
 ADOConnection::_findschema()
 ADOConnection::_findvers()
 ADOConnection::_gencachename()
 ADOConnection::_nconnect()
 ADOConnection::_rs2rs()

Documentation generated on Wed, 23 Jan 2008 19:34:12 -0500 by phpDocumentor 1.4.0