NOBUG mssql - nasty regression causing silent script abort without notice at all...
authorEloy Lafuente <stronk7@moodle.org>
Mon, 30 Aug 2010 10:45:54 +0000 (10:45 +0000)
committerEloy Lafuente <stronk7@moodle.org>
Mon, 30 Aug 2010 10:45:54 +0000 (10:45 +0000)
lib/dml/mssql_native_moodle_database.php

index 3eac2a6..d087eb2 100644 (file)
@@ -1078,11 +1078,11 @@ class mssql_native_moodle_database extends moodle_database {
 
         $sql = "SELECT CAST(DATABASEPROPERTYEX('$this->dbname', 'Collation') AS varchar(255)) AS SQLCollation";
         $this->query_start($sql, null, SQL_QUERY_AUX);
-        $result = sqlsrv_query($this->sqlsrv, $sql);
+        $result = mssql_query($this->mssql, $sql);
         $this->query_end($result);
 
         if ($result) {
-            if ($rawcolumn = sqlsrv_fetch_array($result, SQLSRV_FETCH_ASSOC)) {
+            if ($rawcolumn = mssql_fetch_array($result, SQLSRV_FETCH_ASSOC)) {
                 $this->collation = reset($rawcolumn);
             }
             $this->free_result($result);