Beispiel #1
0
 protected function handleIndexKeys(CreateTable $schema)
 {
     $indexes = $schema->getIndexes();
     if (empty($indexes)) {
         return array();
     }
     $sql = array();
     $table = $schema->getTableName();
     foreach ($indexes as $name => $columns) {
         $sql[] = 'CREATE INDEX ' . $this->wrap($table . '_' . $name) . ' ON ' . $this->wrap($table) . '(' . $this->wrapArray($columns) . ')';
     }
     return $sql;
 }