Permalink
Browse files

Designate a primary key instead of an index

  • Loading branch information...
1 parent fc88993 commit 7cbb7136f5b1c0f49dd25912c755d9cdd4b492aa @iangreenleaf iangreenleaf committed Mar 11, 2010
Showing with 1 addition and 2 deletions.
  1. +1 −2 Db/Files.php
View
3 Db/Files.php
@@ -18,8 +18,7 @@ public static function init()
{
$db = Scisr_Db::getDb();
$create = <<<EOS
-CREATE TABLE IF NOT EXISTS FileInfo (file text, parsed text);
-CREATE INDEX IF NOT EXISTS Files_index_file ON FileInfo (file);
+CREATE TABLE IF NOT EXISTS FileInfo (file text PRIMARY KEY, parsed text);
EOS;
$db->exec($create);
}

0 comments on commit 7cbb713

Please sign in to comment.