* @param string $tablename the name of the table to create.
* @return xmldb_table the table object.
*/
- private function get_test_table(database_manager $dbman, $tablename="testtable") {
+ private function get_test_table($tablename="testtable") {
+ $dbman = $this->tdb->get_manager();
+
$table = new xmldb_table($tablename);
if ($dbman->table_exists($table)) {
$dbman->drop_table($table);
function test_fix_sql_params() {
$DB = $this->tdb;
- $tablename = 'testtable';
+ $table = $this->get_test_table();
+ $tablename = $table->getName();
// Correct table placeholder substitution
$sql = "SELECT * FROM {".$tablename."}";
$dbman = $this->tdb->get_manager();
// Need to test with multiple DBs
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$original_count = count($DB->get_tables());
$DB = $this->tdb;
$dbman = $this->tdb->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('enumfield', XMLDB_TYPE_CHAR, '255', null, null, null, XMLDB_ENUM, array('test','test2','test3'),null);
$DB = $this->tdb;
$dbman = $this->tdb->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$enumvalues = array('test','test2','test3');
$DB = $this->tdb;
$dbman = $this->tdb->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $this->tdb->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $this->tdb->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$this->assertEqual($blob, $record->image);
$this->assertEqual($clob, $DB->get_field($tablename, 'description', array('id' => $id)));
$this->assertEqual($blob, $DB->get_field($tablename, 'image', array('id' => $id)));
+
}
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$this->assertEqual(substr($clob, 0, 500), $record->description);
}
- public function test_update_record_multiple_clobs() {
+ public function test_update_record_multiple_lobs() {
global $CFG;
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
function test_sql_bitand() {
$DB = $this->tdb;
- $sql = "SELECT ".$DB->sql_bitand(10, 3)." AS number ".$DB->sql_null_from_clause();
+ $sql = "SELECT ".$DB->sql_bitand(10, 3)." AS res ".$DB->sql_null_from_clause();
$this->assertEqual($DB->get_field_sql($sql), 2);
}
$not = $DB->sql_bitnot(2);
$notlimited = $DB->sql_bitand($not, 7); // might be positive or negative number which can not fit into PHP INT!
- $sql = "SELECT $notlimited AS number ".$DB->sql_null_from_clause();
+ $sql = "SELECT $notlimited AS res ".$DB->sql_null_from_clause();
$this->assertEqual($DB->get_field_sql($sql), 5);
}
function test_sql_bitor() {
$DB = $this->tdb;
- $sql = "SELECT ".$DB->sql_bitor(10, 3)." AS number ".$DB->sql_null_from_clause();
+ $sql = "SELECT ".$DB->sql_bitor(10, 3)." AS res ".$DB->sql_null_from_clause();
$this->assertEqual($DB->get_field_sql($sql), 11);
}
function test_sql_bitxor() {
$DB = $this->tdb;
- $sql = "SELECT ".$DB->sql_bitxor(10, 3)." AS number ".$DB->sql_null_from_clause();
+ $sql = "SELECT ".$DB->sql_bitxor(10, 3)." AS res ".$DB->sql_null_from_clause();
$this->assertEqual($DB->get_field_sql($sql), 9);
}
function test_sql_modulo() {
$DB = $this->tdb;
- $sql = "SELECT ".$DB->sql_modulo(10, 7)." AS number ".$DB->sql_null_from_clause();
+ $sql = "SELECT ".$DB->sql_modulo(10, 7)." AS res ".$DB->sql_null_from_clause();
$this->assertEqual($DB->get_field_sql($sql), 3);
}
function test_sql_ceil() {
$DB = $this->tdb;
- $sql = "SELECT ".$DB->sql_ceil(665.666)." AS number ".$DB->sql_null_from_clause();
+ $sql = "SELECT ".$DB->sql_ceil(665.666)." AS res ".$DB->sql_null_from_clause();
$this->assertEqual($DB->get_field_sql($sql), 666);
}
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table1 = $this->get_test_table($dbman, "testtable1");
+ $table1 = $this->get_test_table("testtable1");
$tablename1 = $table1->getName();
$table1->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB->insert_record($tablename1, array('name'=>'100'));
- $table2 = $this->get_test_table($dbman, "testtable2");
+ $table2 = $this->get_test_table("testtable2");
$tablename2 = $table2->getName();
$table2->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
- $table2->add_field('number', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, null, null, null, '0');
+ $table2->add_field('res', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, null, null, null, '0');
$table2->add_key('primary', XMLDB_KEY_PRIMARY, array('id'));
$dbman->create_table($table2);
$this->tables[$table2->getName()] = $table2;
- $DB->insert_record($tablename2, array('number'=>100));
+ $DB->insert_record($tablename2, array('res'=>100));
try {
- $sql = "SELECT * FROM {".$tablename1."} t1, {".$tablename2."} t2 WHERE ".$DB->sql_cast_char2int("t1.name")." = t2.number ";
+ $sql = "SELECT * FROM {".$tablename1."} t1, {".$tablename2."} t2 WHERE ".$DB->sql_cast_char2int("t1.name")." = t2.res ";
$records = $DB->get_records_sql($sql);
$this->assertEqual(count($records), 1);
} catch (dml_exception $e) {
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$table->add_field('name', XMLDB_TYPE_CHAR, '255', null, null, null, null, null, null);
- $table->add_field('number', XMLDB_TYPE_NUMBER, '12, 7', null, null, null, null, null, null);
+ $table->add_field('res', XMLDB_TYPE_NUMBER, '12, 7', null, null, null, null, null, null);
$table->add_key('primary', XMLDB_KEY_PRIMARY, array('id'));
$dbman->create_table($table);
$this->tables[$tablename] = $table;
- $DB->insert_record($tablename, array('name'=>'10.10', 'number'=>5.1));
- $DB->insert_record($tablename, array('name'=>'1.10', 'number'=>666));
- $DB->insert_record($tablename, array('name'=>'11.10', 'number'=>0.1));
+ $DB->insert_record($tablename, array('name'=>'10.10', 'res'=>5.1));
+ $DB->insert_record($tablename, array('name'=>'1.10', 'res'=>666));
+ $DB->insert_record($tablename, array('name'=>'11.10', 'res'=>0.1));
- $sql = "SELECT * FROM {".$tablename."} WHERE ".$DB->sql_cast_char2real('name')." > number";
+ $sql = "SELECT * FROM {".$tablename."} WHERE ".$DB->sql_cast_char2real('name')." > res";
$records = $DB->get_records_sql($sql);
$this->assertEqual(count($records), 2);
}
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
return;
}
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);
$DB = $this->tdb;
$dbman = $DB->get_manager();
- $table = $this->get_test_table($dbman);
+ $table = $this->get_test_table();
$tablename = $table->getName();
$table->add_field('id', XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, XMLDB_NOTNULL, XMLDB_SEQUENCE, null, null, null);