diff --git a/lib/setup.php b/lib/setup.php
index 5f1fb1525ec8073202ad435f0830ce6132ee353e..e1c1a110b38333bbb0f0eb30abc70c0917bb3acb 100644
--- a/lib/setup.php
+++ b/lib/setup.php
@@ -150,7 +150,7 @@ class OC_Setup {
 				$dbpass = $options['dbpass'];
 				$dbname = $options['dbname'];
 				$dbhost = $options['dbhost'];
-				$dbtableprefix = $options['dbtableprefix'];
+				$dbtableprefix = isset($options['dbtableprefix']) ? $options['dbtableprefix'] : 'oc_';
 				OC_CONFIG::setValue('dbname', $dbname);
 				OC_CONFIG::setValue('dbhost', $dbhost);
 				OC_CONFIG::setValue('dbtableprefix', $dbtableprefix);