Elgg
Version 6.1
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
engine
schema
migrations
20171021111005_add_subtype_index_to_river_table.php
Go to the documentation of this file.
1
<?php
2
3
use
Phinx\Migration\AbstractMigration
;
4
5
class
AddSubtypeIndexToRiverTable
extends
AbstractMigration {
9
public
function
change
() {
10
11
$table
= $this->table(
'river'
);
12
13
if
(!
$table
->hasIndexByName(
'subtype'
)) {
14
$table
->addIndex([
'subtype'
], [
15
'name'
=>
"subtype"
,
16
'unique'
=>
false
,
17
]);
18
19
$table
->save();
20
}
21
}
22
}
$table
$table
Definition:
user.php:37
AbstractMigration
AddSubtypeIndexToRiverTable
Definition:
20171021111005_add_subtype_index_to_river_table.php:5
AddSubtypeIndexToRiverTable\change
change()
Adds 'subtype' as index to the river table.
Definition:
20171021111005_add_subtype_index_to_river_table.php:9
Generated on Thu Dec 12 2024 00:00:22 for Elgg by
1.8.11