summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorThomas Müller <thomas.mueller@tmit.eu>2013-06-14 11:21:02 -0700
committerThomas Müller <thomas.mueller@tmit.eu>2013-06-14 11:21:02 -0700
commit0ac7c5712a18b01057ebaf5819cfe12700a86a3e (patch)
treeba17e57fe2fb4077058a77d8ab32bd38cbeaa940 /tests
parent23446542360fa930614735a426eb4273a202e9ae (diff)
parent9498cf959f0110182ac682d1784a6594a9f27936 (diff)
downloadnextcloud-server-0ac7c5712a18b01057ebaf5819cfe12700a86a3e.tar.gz
nextcloud-server-0ac7c5712a18b01057ebaf5819cfe12700a86a3e.zip
Merge pull request #3721 from owncloud/oracle_setup_fixes
Oracle setup fixes
Diffstat (limited to 'tests')
-rw-r--r--tests/lib/dbschema.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/lib/dbschema.php b/tests/lib/dbschema.php
index 6631c929cf2..59f203993ef 100644
--- a/tests/lib/dbschema.php
+++ b/tests/lib/dbschema.php
@@ -94,13 +94,18 @@ class Test_DBSchema extends PHPUnit_Framework_TestCase {
break;
case 'pgsql':
$sql = "SELECT tablename AS table_name, schemaname AS schema_name "
- . "FROM pg_tables WHERE schemaname NOT LIKE 'pg_%' "
+ . "FROM pg_tables WHERE schemaname NOT LIKE 'pg_%' "
. "AND schemaname != 'information_schema' "
. "AND tablename = '".$table."'";
$query = OC_DB::prepare($sql);
$result = $query->execute(array());
$exists = $result && $result->fetchOne();
break;
+ case 'oci':
+ $sql = 'SELECT table_name FROM user_tables WHERE table_name = ?';
+ $result = \OC_DB::executeAudited($sql, array($table));
+ $exists = (bool)$result->fetchOne(); //oracle uses MDB2 and returns null
+ break;
case 'mssql':
$sql = "SELECT * FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_NAME = '{$table}'";
$query = OC_DB::prepare($sql);