ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
class.ilDBInnoDB.php
Go to the documentation of this file.
1<?php
2
3/* Copyright (c) 1998-2012 ILIAS open source, Extended GPL, see docs/LICENSE */
4
5include_once("./Services/Database/classes/MDB2/class.ilDBMySQL.php");
6
18class ilDBInnoDB extends ilDBMySQL {
19
23 function getDBType() {
24 return "innodb";
25 }
26
27
31 function initConnection() {
32 // SET 'max_allowed_packet' (only possible for mysql version 4)
33 $this->setMaxAllowedPacket();
34
35 // NOTE: Two sourcecodes use this or a similar handling:
36 // - classes/class.ilDB.php
37 // - setup/classes/class.ilClient.php
38
39 $this->query("SET NAMES utf8");
40 if (DEVMODE == 1) {
41 $this->query("SET SESSION SQL_MODE = 'ONLY_FULL_GROUP_BY'");
42 }
43 $this->setStorageEngine('INNODB');
44 }
45
46
50 function supportsFulltext() {
51 return false;
52 }
53
54
55 protected function getCreateTableOptions() {
56 // InnoDB is default engine for MySQL >= 5.5
57 return array( 'type' => 'InnoDB' );
58 }
59
60
61 public function getStorageEngine() {
62 return 'InnoDB';
63 }
64}
65
An exception for terminatinating execution or to throw for unit testing.
MySQL InnoDB Database Wrapper.
initConnection()
Initialize the database connection.
supportsFulltext()
Is fulltext index supported?
getDBType()
Get DB Type.
getCreateTableOptions()
Get options for the create table statement.
MySQL Database Wrapper.
query($sql, $a_handle_error=true)
Query.Example:"SELECT * FROM data"For multiple similar queries/manipulations you may use prepare() an...
setStorageEngine($a_storage_engine)
Set the storage engine.
setMaxAllowedPacket()
Set maximum allowed packet size.