Skip to content

Commit

Permalink
MDL-37420 rework pg schema (partial backport take2)
Browse files Browse the repository at this point in the history
  • Loading branch information
stronk7 committed Jan 11, 2013
1 parent fa02465 commit 0eda863
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion enrol/database/tests/adodb_test.php
Expand Up @@ -67,7 +67,11 @@ public function test_read_table() {


case 'pgsql_native_moodle_database': case 'pgsql_native_moodle_database':
set_config('dbtype', 'postgres7', 'enrol_database'); set_config('dbtype', 'postgres7', 'enrol_database');
set_config('dbsetupsql', 'SET NAMES \'UTF-8\'', 'enrol_database'); $setupsql = "SET NAMES 'UTF-8'";
if (!empty($CFG->dboptions['dbschema'])) {
$setupsql .= "; SET search_path = '".$CFG->dboptions['dbschema']."'";
}
set_config('dbsetupsql', $setupsql, 'enrol_database');
set_config('dbsybasequoting', '0', 'enrol_database'); set_config('dbsybasequoting', '0', 'enrol_database');
if (!empty($CFG->dboptions['dbsocket']) and ($CFG->dbhost === 'localhost' or $CFG->dbhost === '127.0.0.1')) { if (!empty($CFG->dboptions['dbsocket']) and ($CFG->dbhost === 'localhost' or $CFG->dbhost === '127.0.0.1')) {
if (strpos($CFG->dboptions['dbsocket'], '/') !== false) { if (strpos($CFG->dboptions['dbsocket'], '/') !== false) {
Expand Down

0 comments on commit 0eda863

Please sign in to comment.