Elgg
Version 6.1
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
engine
schema
migrations
20210225131119_increase_relationship_column_length.php
Go to the documentation of this file.
1
<?php
2
3
use
Phinx\Migration\AbstractMigration
;
4
use
Phinx\Db\Adapter\MysqlAdapter
;
5
6
class
IncreaseRelationshipColumnLength
extends
AbstractMigration {
7
11
public
function
change
() {
12
if
(!$this->hasTable(
'entity_relationships'
)) {
13
return
;
14
}
15
16
$table
= $this->table(
'entity_relationships'
);
17
if
(!
$table
->hasColumn(
'relationship'
)) {
18
return
;
19
}
20
21
$table
->changeColumn(
'relationship'
,
'string'
, [
22
'limit'
=> MysqlAdapter::TEXT_SMALL,
23
]);
24
$table
->update();
25
}
26
}
MysqlAdapter
IncreaseRelationshipColumnLength
Definition:
20210225131119_increase_relationship_column_length.php:6
IncreaseRelationshipColumnLength\change
change()
Update the relationship column to a larger size.
Definition:
20210225131119_increase_relationship_column_length.php:11
$table
$table
Definition:
user.php:37
AbstractMigration
Generated on Wed Dec 4 2024 00:00:22 for Elgg by
1.8.11