summaryrefslogtreecommitdiffstats
path: root/lib/app.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/app.php')
-rw-r--r--lib/app.php12
1 files changed, 10 insertions, 2 deletions
diff --git a/lib/app.php b/lib/app.php
index 55b4543ec9f..c6f6e92e60e 100644
--- a/lib/app.php
+++ b/lib/app.php
@@ -172,9 +172,17 @@ class OC_App{
return array();
}
$apps=array('files');
- $query = OC_DB::prepare( 'SELECT `appid` FROM `*PREFIX*appconfig`'
- .' WHERE `configkey` = \'enabled\' AND `configvalue`=\'yes\'' );
+ $sql = 'SELECT `appid` FROM `*PREFIX*appconfig`'
+ .' WHERE `configkey` = \'enabled\' AND `configvalue`=\'yes\'';
+ if (OC_Config::getValue( 'dbtype', 'sqlite' ) === 'oci') { //FIXME oracle hack
+ $sql = 'SELECT `appid` FROM `*PREFIX*appconfig`'
+ .' WHERE `configkey` = \'enabled\' AND to_char(`configvalue`)=\'yes\'';
+ }
+ $query = OC_DB::prepare( $sql );
$result=$query->execute();
+ if( \OC_DB::isError($result)) {
+ throw new DatabaseException($result->getMessage(), $query);
+ }
while($row=$result->fetchRow()) {
if(array_search($row['appid'], $apps)===false) {
$apps[]=$row['appid'];