ADODB_odbc_mssql Class Reference

Inheritance diagram for ADODB_odbc_mssql:

Inheritance graph
[legend]
Collaboration diagram for ADODB_odbc_mssql:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 ADODB_odbc_mssql ()
 ServerInfo ()
 IfNull ($field, $ifNull)
 _insertid ()
 MetaForeignKeys ($table, $owner=false, $upper=false)
MetaTables ($ttype=false, $showSchema=false, $mask=false)
MetaColumns ($table)
MetaIndexes ($table, $primary=false)
 _query ($sql, $inputarr)
 SetTransactionMode ($transaction_mode)
MetaPrimaryKeys ($table)
SelectLimit ($sql, $nrows=-1, $offset=-1, $inputarr=false, $secs2cache=0)
 SQLDate ($fmt, $col=false)

Public Attributes

 $databaseType = 'odbc_mssql'
 $fmtDate = "'Y-m-d'"
 uppercase function
 $fmtTimeStamp = "'Y-m-d H:i:s'"
 used by DBDate() as the default date format used by the database
 $_bindInputArray = true
 A boolean variable to state whether its a persistent connection or normal connection. */.
 $metaTablesSQL = "select name,case when type='U' then 'T' else 'V' end from sysobjects where (type='U' or type='V') and (name not in ('sysallocations','syscolumns','syscomments','sysdepends','sysfilegroups','sysfiles','sysfiles1','sysforeignkeys','sysfulltextcatalogs','sysindexes','sysindexkeys','sysmembers','sysobjects','syspermissions','sysprotects','sysreferences','systypes','sysusers','sysalternates','sysconstraints','syssegments','REFERENTIAL_CONSTRAINTS','CHECK_CONSTRAINTS','CONSTRAINT_TABLE_USAGE','CONSTRAINT_COLUMN_USAGE','VIEWS','VIEW_TABLE_USAGE','VIEW_COLUMN_USAGE','SCHEMATA','TABLES','TABLE_CONSTRAINTS','TABLE_PRIVILEGES','COLUMNS','COLUMN_DOMAIN_USAGE','COLUMN_PRIVILEGES','DOMAINS','DOMAIN_CONSTRAINTS','KEY_COLUMN_USAGE'))"
 $metaColumnsSQL = "select c.name,t.name,c.length from syscolumns c join systypes t on t.xusertype=c.xusertype join sysobjects o on o.id=c.id where o.name='%s'"
 $hasTop = 'top'
 supports affected rows for update/delete?
 $sysDate = 'GetDate()'
 Use 'true' to store the item compressed (uses zlib).
 $sysTimeStamp = 'GetDate()'
 name of function that returns the current date
 $leftOuter = '*='
 indicates that all fields in order by must be unique
 $rightOuter = '=*'
 operator to use for left outer join in WHERE clause
 $substr = 'substring'
 default concat operator -- change to || for Oracle/Interbase
 $length = 'len'
 substring operator
 $ansiOuter = true
 operator to use for right outer join in WHERE clause
 $identitySQL = 'select @@IDENTITY'
 $hasInsertID = true
 $connectStmt = 'SET CONCAT_NULL_YIELDS_NULL OFF'


Detailed Description

Definition at line 23 of file adodb-odbc_mssql.inc.php.


Member Function Documentation

ADODB_odbc_mssql.ADODB_odbc_mssql (  ) 

Definition at line 43 of file adodb-odbc_mssql.inc.php.

References ADODB_odbc.ADODB_odbc().

Here is the call graph for this function:

ADODB_odbc_mssql.ServerInfo (  ) 

Get server version info...

Returns:
An array with 2 elements: $arr['string'] is the description string, and $arr[version] is the version (also a string).

Reimplemented from ADODB_odbc.

Definition at line 50 of file adodb-odbc_mssql.inc.php.

References $ADODB_FETCH_MODE, $arr, $row, ADOConnection._findvers(), and ADOConnection.GetRow().

Here is the call graph for this function:

ADODB_odbc_mssql.IfNull ( field,
ifNull 
)

Reimplemented from ADOConnection.

Definition at line 63 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql._insertid (  ) 

Definition at line 68 of file adodb-odbc_mssql.inc.php.

References ADOConnection.GetOne().

Here is the call graph for this function:

ADODB_odbc_mssql.MetaForeignKeys ( table,
owner = false,
upper = false 
)

Returns:
assoc array where keys are tables, and values are foreign keys

Reimplemented from ADOConnection.

Definition at line 79 of file adodb-odbc_mssql.inc.php.

References $ADODB_FETCH_MODE, $arr, $sql, $v, ADOConnection.GetArray(), and ADOConnection.qstr().

Here is the call graph for this function:

& ADODB_odbc_mssql.MetaTables ( ttype = false,
showSchema = false,
mask = false 
)

Parameters:
ttype can either be 'VIEW' or 'TABLE' or false. If false, both views and tables are returned. "VIEW" returns only views "TABLE" returns only tables
showSchema returns the schema/user with the table name, eg. USER.TABLE
mask is the input mask - only supported by oci8 and postgresql
Returns:
array of tables for current database.

Reimplemented from ADOConnection.

Definition at line 118 of file adodb-odbc_mssql.inc.php.

References debug, ADOConnection.MetaTables(), and ADOConnection.qstr().

Here is the call graph for this function:

& ADODB_odbc_mssql.MetaColumns ( table  ) 

Reimplemented from ADODB_odbc.

Definition at line 133 of file adodb-odbc_mssql.inc.php.

References $arr, and ADOConnection.MetaColumns().

Here is the call graph for this function:

& ADODB_odbc_mssql.MetaIndexes ( table,
primary = false 
)

Definition at line 140 of file adodb-odbc_mssql.inc.php.

References $ADODB_FETCH_MODE, $row, $rs, $sql, ADOConnection.Execute(), ADOConnection.qstr(), and ADOConnection.SetFetchMode().

Here is the call graph for this function:

ADODB_odbc_mssql._query ( sql,
inputarr 
)

Reimplemented from ADODB_odbc.

Definition at line 180 of file adodb-odbc_mssql.inc.php.

References $sql, and ADODB_odbc._query().

Here is the call graph for this function:

ADODB_odbc_mssql.SetTransactionMode ( transaction_mode  ) 

Reimplemented from ADOConnection.

Definition at line 186 of file adodb-odbc_mssql.inc.php.

References ADOConnection.Execute().

Here is the call graph for this function:

& ADODB_odbc_mssql.MetaPrimaryKeys ( table  ) 

Reimplemented from ADODB_odbc.

Definition at line 199 of file adodb-odbc_mssql.inc.php.

References $ADODB_FETCH_MODE, ADOConnection.$false, $schema, $sql, ADOConnection._findschema(), and ADOConnection.GetCol().

Here is the call graph for this function:

& ADODB_odbc_mssql.SelectLimit ( sql,
nrows = -1,
offset = -1,
inputarr = false,
secs2cache = 0 
)

Will select, getting rows from $offset (1-based), for $nrows. This simulates the MySQL "select * from table limit $offset,$nrows" , and the PostgreSQL "select * from table limit $nrows offset $offset". Note that MySQL and PostgreSQL parameter ordering is the opposite of the other. eg. SelectLimit('select * from table',3); will return rows 1 to 3 (1-based) SelectLimit('select * from table',3,2); will return rows 3 to 5 (1-based)

Uses SELECT TOP for Microsoft databases (when $this->hasTop is set) BUG: Currently SelectLimit fails with $sql with LIMIT or TOP clause already set

Parameters:
sql 
[offset] is the row to start calculations from (1-based)
[nrows] is the number of rows to get
[inputarr] array of bind variables
[secs2cache] is a private parameter only used by jlim
Returns:
the recordset ($rs->databaseType == 'array')

Reimplemented from ADOConnection.

Definition at line 223 of file adodb-odbc_mssql.inc.php.

References $rs, $sql, ADOConnection.Execute(), and ADOConnection.SelectLimit().

Here is the call graph for this function:

ADODB_odbc_mssql.SQLDate ( fmt,
col = false 
)

Reimplemented from ADOConnection.

Definition at line 236 of file adodb-odbc_mssql.inc.php.

References $s, and ADOConnection.qstr().

Here is the call graph for this function:


Member Data Documentation

ADODB_odbc_mssql.$databaseType = 'odbc_mssql'

Reimplemented from ADODB_odbc.

Definition at line 24 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$fmtDate = "'Y-m-d'"

uppercase function

Reimplemented from ADODB_odbc.

Definition at line 25 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$fmtTimeStamp = "'Y-m-d H:i:s'"

used by DBDate() as the default date format used by the database

Reimplemented from ADODB_odbc.

Definition at line 26 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$_bindInputArray = true

A boolean variable to state whether its a persistent connection or normal connection. */.

Reimplemented from ADODB_odbc.

Definition at line 27 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$metaTablesSQL = "select name,case when type='U' then 'T' else 'V' end from sysobjects where (type='U' or type='V') and (name not in ('sysallocations','syscolumns','syscomments','sysdepends','sysfilegroups','sysfiles','sysfiles1','sysforeignkeys','sysfulltextcatalogs','sysindexes','sysindexkeys','sysmembers','sysobjects','syspermissions','sysprotects','sysreferences','systypes','sysusers','sysalternates','sysconstraints','syssegments','REFERENTIAL_CONSTRAINTS','CHECK_CONSTRAINTS','CONSTRAINT_TABLE_USAGE','CONSTRAINT_COLUMN_USAGE','VIEWS','VIEW_TABLE_USAGE','VIEW_COLUMN_USAGE','SCHEMATA','TABLES','TABLE_CONSTRAINTS','TABLE_PRIVILEGES','COLUMNS','COLUMN_DOMAIN_USAGE','COLUMN_PRIVILEGES','DOMAINS','DOMAIN_CONSTRAINTS','KEY_COLUMN_USAGE'))"

Reimplemented from ADOConnection.

Definition at line 28 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$metaColumnsSQL = "select c.name,t.name,c.length from syscolumns c join systypes t on t.xusertype=c.xusertype join sysobjects o on o.id=c.id where o.name='%s'"

Definition at line 29 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$hasTop = 'top'

supports affected rows for update/delete?

Reimplemented from ADOConnection.

Definition at line 30 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$sysDate = 'GetDate()'

Use 'true' to store the item compressed (uses zlib).

Reimplemented from ADOConnection.

Definition at line 31 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$sysTimeStamp = 'GetDate()'

name of function that returns the current date

Reimplemented from ADOConnection.

Definition at line 32 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$leftOuter = '*='

indicates that all fields in order by must be unique

Reimplemented from ADOConnection.

Definition at line 33 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$rightOuter = '=*'

operator to use for left outer join in WHERE clause

Reimplemented from ADOConnection.

Definition at line 34 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$substr = 'substring'

default concat operator -- change to || for Oracle/Interbase

Reimplemented from ADOConnection.

Definition at line 35 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$length = 'len'

substring operator

Reimplemented from ADOConnection.

Definition at line 36 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$ansiOuter = true

operator to use for right outer join in WHERE clause

Reimplemented from ADOConnection.

Definition at line 37 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$identitySQL = 'select @@IDENTITY'

Definition at line 38 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$hasInsertID = true

Reimplemented from ADOConnection.

Definition at line 39 of file adodb-odbc_mssql.inc.php.

ADODB_odbc_mssql.$connectStmt = 'SET CONCAT_NULL_YIELDS_NULL OFF'

Definition at line 40 of file adodb-odbc_mssql.inc.php.


The documentation for this class was generated from the following file:
This documentation is part of typo3-unleashed.net.
It's an automatically created code documentation of the TYPO3 Content Management System.
Created with doxygen