From c9462d0c1e2493a7399b1dbd21e23b215e97f808 Mon Sep 17 00:00:00 2001 From: svncommit Date: Thu, 27 Oct 2005 13:40:37 +0000 Subject: added all mdb2 drivers --- program/lib/MDB2/Driver/Native/sqlite.php | 89 +++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) create mode 100755 program/lib/MDB2/Driver/Native/sqlite.php (limited to 'program/lib/MDB2/Driver/Native/sqlite.php') diff --git a/program/lib/MDB2/Driver/Native/sqlite.php b/program/lib/MDB2/Driver/Native/sqlite.php new file mode 100755 index 000000000..987473e14 --- /dev/null +++ b/program/lib/MDB2/Driver/Native/sqlite.php @@ -0,0 +1,89 @@ + | +// +----------------------------------------------------------------------+ +// +// $Id$ +// + +/** + * MDB2 SQLite driver for the native module + * + * @package MDB2 + * @category Database + * @author Lukas Smith + */ +class MDB2_Driver_Native_sqlite +{ + var $db_index; + + // {{{ constructor + + /** + * Constructor + */ + function __construct($db_index) + { + $this->db_index = $db_index; + } + + function MDB2_Driver_Native_sqlite($db_index) + { + $this->__construct($db_index); + } + + // }}} + // {{{ getInsertID() + + /** + * get last insert ID + * + * @return mixed MDB2 Error Object or id + * @access public + */ + function getInsertID() + { + $db =& $GLOBALS['_MDB2_databases'][$this->db_index]; + return @sqlite_last_insert_rowid($db->connection); + } +} +?> \ No newline at end of file -- cgit v1.2.3