Skip to content

Commit

Permalink
Add index on c_quiz_question_rel_category
Browse files Browse the repository at this point in the history
  • Loading branch information
AngelFQC committed May 30, 2016
1 parent bfa0cfd commit 11e38c9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions app/Migrations/Schema/V111/Version111.php
Expand Up @@ -263,6 +263,7 @@ public function up(Schema $schema)
$this->addSql("INSERT INTO settings_options (variable, value, display_text) VALUES ('ticket_allow_student_add', 'true', 'Yes'), ('ticket_allow_student_add', 'false', 'No')");
$this->addSql("INSERT INTO settings_options (variable, value, display_text) VALUES ('ticket_allow_category_edition', 'true', 'Yes'), ('ticket_allow_category_edition', 'false', 'No')");

$this->addSql("ALTER TABLE c_quiz_question_rel_category ADD INDEX idx_qqrc_qid (question_id)");
}
}

Expand Down
3 changes: 2 additions & 1 deletion src/Chamilo/CourseBundle/Entity/CQuizQuestionRelCategory.php
Expand Up @@ -11,7 +11,8 @@
* @ORM\Table(
* name="c_quiz_question_rel_category",
* indexes={
* @ORM\Index(name="course", columns={"c_id"})
* @ORM\Index(name="course", columns={"c_id"}),
* @ORM\Index(name="idx_qqrc_qid", columns={"question_id"})
* }
* )
* @ORM\Entity
Expand Down

0 comments on commit 11e38c9

Please sign in to comment.