瀏覽代碼

Fix table creation when there is no PK

Nathaniel van Diepen 6 年之前
父節點
當前提交
0481b14f4a
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      PDO/table.class.php

+ 2 - 0
PDO/table.class.php

@@ -143,6 +143,8 @@
 				$pk = $this->primaryKey();
 				if(count($pk)){
 					$pk = ", primary key (".implode(',', $pk).")";
+				}else{
+					$pk = '';
 				}
 				$index = '';
 				foreach($this->index as $name => $idx){