src/Phinx/Db/Adapter/PostgresAdapter.php 1 location
|
@@ 707-715 (lines=9) @@
|
704 |
|
/** |
705 |
|
* {@inheritdoc} |
706 |
|
*/ |
707 |
|
protected function getAddForeignKeyInstructions(Table $table, ForeignKey $foreignKey) |
708 |
|
{ |
709 |
|
$alter = sprintf( |
710 |
|
'ADD %s', |
711 |
|
$this->getForeignKeySqlDefinition($foreignKey, $table->getName()) |
712 |
|
); |
713 |
|
|
714 |
|
return new AlterInstructions([$alter]); |
715 |
|
} |
716 |
|
|
717 |
|
/** |
718 |
|
* {@inheritdoc} |
src/Phinx/Db/Adapter/MysqlAdapter.php 1 location
|
@@ 622-630 (lines=9) @@
|
619 |
|
/** |
620 |
|
* {@inheritdoc} |
621 |
|
*/ |
622 |
|
protected function getAddForeignKeyInstructions( Table $table, ForeignKey $foreignKey ) { |
623 |
|
$alter = sprintf( |
624 |
|
'ADD %s', |
625 |
|
$this->getForeignKeySqlDefinition( $foreignKey ) |
626 |
|
); |
627 |
|
|
628 |
|
return new AlterInstructions( [ $alter ] ); |
629 |
|
} |
630 |
|
|
631 |
|
/** |
632 |
|
* {@inheritdoc} |
633 |
|
*/ |