This is an old revision of the document!
ADOdb Version 6
This description relates to prototype versions of ADOdb Version 6 and is subject to change
About ADOdb Version 6
Important Links
ADOdb Version 6 is a major refactoring (not rewrite) of the main portion of the ADOdb code into a PSR Compliant codebase featuring autoloading and improved logging capabilities. Its focus is on the main Database Extraction features, as well as Meta Functions, The Data Dictionary, the Time library and Session management. There are no plans at this moment to move any of the add-on features, or deprecated drivers forward. Some functions may be discarded, even though the product is generally backwards compatible with version 5.
Highlights
PHP Version
The minimum required version of PHP for this product is 7.4
Logging
All of the logging functions of ADOdb have been offloaded to the Monolog library, allowing you to define individual streams for both debug mode and error trapping. Logging for error handling is now always on, and unaffected by the debug mode flag, although messages along that channel can be discarded by setting up the appropriate monolog stream. For more about logging, visit Logging
Autoloading
ADOdb becomes a PSR level 4 autoload library. An appropriate autoloader class is required.
Encapsulation
ADOdb Version 6 does not use any globalized variables or constants. Each connection becomes a standalone entity, with its own set of definitions, each definition representing an ADOdb Version 5 global or constant. This means, for example that a connection to one database might use numeric arrays in record fetch operations, while a second might simultaneously use associative arrays.
Data Quality
All methods are now type hinted, both on input and output variables. This allows us to eliminate unexpected return types. In addition, all internal methods are now protected.
Footprint
By moving the code of most of the methods from the core files into JIT loadable classes, the footprint of ADOdb becomes much smaller
Easier to understand driver options
Driver specific options are now directly exposed under the name ** OEM Flags **. Each drivers available options can be viewed and modified as necessary, then loaded into the driver. This feature replaces a number of individually crafted items, such as setConnectionParameter(), optionFlags or driverFlags
Feature Enhancements
Part of the new development is to include requested feature that did not appear in version 5. Examples are:
- Support for both GEO and JSON datatypes in the data dictionary and meta functions.
- Additional metaIndex feature
- Additional Date/Time features
Example Connections
ADOdb Version 5
define('ADODB_FETCH_MODE',1); define('ADODB_ASSOC_CASE',0); include 'adodb/adodb.inc.php'; $db = newADOConnection('mysqli'); $db->connect('localhost','user','password','database');
ADOdb Version 6 Equivalent Connection
$definitions = new ADOdb\ADOConnectionDefinitions; $definitions->driver = 'mysqli'; $definitions->fetchMode = $definitions::ADODB_FETCH_ASSOC; $definitions->assocCase = $definitions::ADODB_ASSOC_CASE_UPPER; $obj = new ADOdb\connector($definitions); $db = $obj->connect('localhost','user','password','database');
Session Management Module
The session management module is now an integrated part of the ADOdb core object. It is now substantially easier to add additional modules such as compression or encryption. The session information can be me unserialized with standard PHP function. The session class itself can be extended much more easily. For more information, see Session Management With V6
Results Caching Service
The caching service supports connections via Memcache servers or APCu . Connections via disk service are no longer supported. For more information see V6 Caching Services
Methods removed in this release
- Anything to do with magic quotes
- Anything to do with file based caching. Only memcache is supported.
- q() - use quote()
- errorNative() - use errorNo()
- nextId() - use genId()
- query() - use execute()
- limitQuery() use selectLimit()
- disconnect() - use close()
- unixDate() - No longer a static method
- escape() - use addQ
- commitLock() - use commitTrans()
- rollBackLock() - use rollBackTrans()
- getRows() - use getArray()
- free() - use close
- numRows() - use recordCount
- numcols() - use fieldcount
- absolutePosition() - use currentRow()
- setConnectionParameter - use ADOOemFlags class
- po_Insert_ID() - Also supported databases support insert_id()
Other Changes
- $transCnt and $transOff are no longer public, use getTransCnt/setTransCnt getTransOff/setTransOff instead
- undocumented constant ADODB_NEVER_PERSIST removed
- Pear compatibility removed
- Pear ADODB_COMPAT_FETCH removed
Pages in this namespace
- Unsupported Addons
- ADOdb XML Schema
- V6 Caching Service
- ADOdb v6 Code Refactoring
- Using Version 6 Connections
- Index Of Database Drivers
- Microsoft Access
- ADO
- The V6 Connection Matrix
- Feature Comparison Matrix
- Firebird & Interbase
- List of Drivers To Be Removed / Merged
- Frontbase
- IBM DB2
- IBM Informix
- LDAP
- Microsoft SQL Server
- MySQL
- Legacy MySQL drivers
- Netezza
- ODBC
- ODBTP
- Oracle
- PDO
- PostgreSQL
- Proxy
- SAP Advantage Database Server
- SAP Adaptive Server Enterprise
- SAP MaxDB
- SAP SQLAnywhere
- SQLite Database
- Supported Databases
- Sybase
- Plain Text
- Unsupported Drivers
- Visual Foxpro
- ADOdb Date/Time Library
- V6 Session Management Service
- Data Dictionary
- actualType
- addColumnSql
- adoFieldObject
- alterColumnSql
- changeTableSql
- Dictionary Column Attributes
- createDatabase
- createIndexSql
- createTableSql
- The Data Dictionary
- dropColumnSql
- dropIndexSql
- dropTableSql
- executeSqlArray
- getActualType
- getCommentSql
- getTableCasing
- metaColumnNames
- metaColumns
- metaDatabases
- metaForeignKeys
- metaIndexes
- metaPrimaryKeys
- metaProcedures
- metaTables
- metaTransaction
- metaType
- renameColumnSql
- renameTableSql
- serverInfo
- setActualType
- setCommentSql
- setTableCasing
- Structured Schema Management
- ADOdb-xmlschema
- ADOdb Logging
- Marks Scratchpad
- MetaObject Structure Prototype
- PHP 7
- Reference Manual
- The ADOConnectionDefinitions Class
- ADOdb\time\ADODateTimeDefinitions
- $ADODB_ANSI_PADDING_OFF
- ADOConnectionDefinitions::assocCase
- $ADODB_CACHE_CLASS
- $ADODB_CACHE_DIR
- $ADOConnectionDefinitions::countRecords
- ADOConnectionDefinitions::defaultActualType
- ADOConnectionDefinitions::defaultMetaType
- ADOConnectionDefinitions::fetchMode
- $ADOConnectionDefinitions::forceType
- $ADOConnectionDefinitions::getOneEOF
- $ADOConnectionDefinitions::language
- ADOConnectionDefinitions::quoteFieldNames
- $ADOConnectionDefinitions::assumeValidDriver
- Connection Reference Manual
- addQ
- The ADORecordSet_array Object
- adoNewConnection
- affected_rows
- autoExecute
- beginTrans
- bindDate
- bindTimeStamp
- blobDecode
- blobEncode
- cacheExecute
- cacheFlush
- cacheGetAll
- cacheGetAssoc
- cacheGetCol
- cacheGetOne
- cacheGetRow
- cachePageExecute
- cacheSelectLimit
- charMax
- close
- commitTrans
- completeTrans
- concat
- connector::connect
- createSequence
- currentRow
- day
- dbDate
- dbTimeStamp
- debugLogMarker()
- dow
- dropSequence
- errorMsg
- execute
- failTrans
- fetchInto
- fnExecute & fnCacheExecute
- genId
- getAll
- getArray
- getAssoc
- getCol
- getFetchMode
- getInsertSql
- getMedian
- getOne
- getRandRow
- getRow
- getRowAssoc
- getUpdateSql
- hasFailedTrans
- ifNull
- ignoreErrors
- inParameter
- insert_Id
- isConnected
- lastPageNo
- metaError
- metaErrorMsg
- month
- connector::nConnect
- offsetDate
- outParameter
- pageExecute
- param
- connector::pConnect
- prepare
- po_recordCount
- prepareSp
- qStr
- Quote
- recordCount
- replace
- rollbackTrans
- rowLock
- rsFilter
- selectDb
- selectLimit
- setCharSet
- setDateLocale
- setFetchMode
- setTransactionMode
- sqlDate
- startTrans
- substr
- textMax
- getTransCnt()
- transOff
- unixDate
- unixTimeStamp
- updateBlob
- updateBlobFile
- updateClob
- userDate
- userTimeStamp
- year
- Recordset Methods Reference Manual
- ADOdb6 Reference Guide
- V6 Resources
- Session Management
- Session Management Reference
- $ADODB_SESSION_EXPIRE_NOTIFY
- adodb_session_regenerate_id
- $ADODB_SESS_CONN
- adodb_unserialize
- ADOdb_Session::clob
- ADOdb_Session::config
- ADOdb_Session::database
- ADOdb_Session::debug
- ADOdb_Session::driver
- ADOdb_Session::encryptionKey
- ADOdb_Session::expireNotify
- ADOdb_Session::filter
- ADOdb_Session::host
- ADOdb_Session::lifetime
- ADOdb_Session::optimize
- ADOdb_Session::password
- ADOdb_Session::persist
- ADOdb_Session::table
- ADOdb_Session::user
- Version 6 Session Management
- Upgrading From V1 ADOdb Session Handling
- Session Management Reference
- V6 Session Management
- V6 Resources
- Structured Schema Management
- User Guide
- ADOdb Active Record
- Maximum String Lengths
- Debug Mode
- Deprecated Functionality
- Error Handling In ADOdb
- learn_abstraction
- learn_bind
- learn_caching
- learn_dictionary
- learn_extensions
- learn_fields
- learn_multidatabase
- Memcached Setup
- Moving from MySQL to ADOdb
- ADOdb & Oracle
- Tips on Writing Portable SQL Using ADOdb
- Stored Procedure Example
- Transaction Handling In ADOdb
- User Guide
