src/Phinx/Db/Adapter/SqlServerAdapter.php 1 location
|
@@ 481-491 (lines=11) @@
|
| 478 |
|
/** |
| 479 |
|
* {@inheritdoc} |
| 480 |
|
*/ |
| 481 |
|
protected function getAddColumnInstructions(Table $table, Column $column) |
| 482 |
|
{ |
| 483 |
|
$alter = sprintf( |
| 484 |
|
'ALTER TABLE %s ADD %s %s', |
| 485 |
|
$table->getName(), |
| 486 |
|
$this->quoteColumnName($column->getName()), |
| 487 |
|
$this->getColumnSqlDefinition($column) |
| 488 |
|
); |
| 489 |
|
|
| 490 |
|
return new AlterInstructions([], [$alter]); |
| 491 |
|
} |
| 492 |
|
|
| 493 |
|
/** |
| 494 |
|
* {@inheritdoc} |
src/Phinx/Db/Adapter/SQLiteAdapter.php 1 location
|
@@ 375-384 (lines=10) @@
|
| 372 |
|
/** |
| 373 |
|
* {@inheritdoc} |
| 374 |
|
*/ |
| 375 |
|
protected function getAddColumnInstructions(Table $table, Column $column) |
| 376 |
|
{ |
| 377 |
|
$alter = sprintf( |
| 378 |
|
'ADD COLUMN %s %s', |
| 379 |
|
$this->quoteColumnName($column->getName()), |
| 380 |
|
$this->getColumnSqlDefinition($column) |
| 381 |
|
); |
| 382 |
|
|
| 383 |
|
return new AlterInstructions([$alter]); |
| 384 |
|
} |
| 385 |
|
|
| 386 |
|
/** |
| 387 |
|
* Returns the original CREATE statement for the give table |