|
@@ 4877-4887 (lines=11) @@
|
| 4874 |
|
/** |
| 4875 |
|
* @see QueryWriter::addColumn |
| 4876 |
|
*/ |
| 4877 |
|
public function addColumn( $type, $column, $field ) |
| 4878 |
|
{ |
| 4879 |
|
$table = $type; |
| 4880 |
|
$type = $field; |
| 4881 |
|
$table = $this->esc( $table ); |
| 4882 |
|
$column = $this->esc( $column ); |
| 4883 |
|
|
| 4884 |
|
$type = ( isset( $this->typeno_sqltype[$type] ) ) ? $this->typeno_sqltype[$type] : ''; |
| 4885 |
|
|
| 4886 |
|
$this->adapter->exec( "ALTER TABLE $table ADD $column $type " ); |
| 4887 |
|
} |
| 4888 |
|
|
| 4889 |
|
/** |
| 4890 |
|
* @see QueryWriter::updateRecord |
|
@@ 6408-6419 (lines=12) @@
|
| 6405 |
|
/** |
| 6406 |
|
* @see QueryWriter::widenColumn |
| 6407 |
|
*/ |
| 6408 |
|
public function widenColumn( $type, $column, $datatype ) |
| 6409 |
|
{ |
| 6410 |
|
$table = $type; |
| 6411 |
|
$type = $datatype; |
| 6412 |
|
|
| 6413 |
|
$table = $this->esc( $table ); |
| 6414 |
|
$column = $this->esc( $column ); |
| 6415 |
|
|
| 6416 |
|
$newtype = $this->typeno_sqltype[$type]; |
| 6417 |
|
|
| 6418 |
|
$this->adapter->exec( "ALTER TABLE $table \n\t ALTER COLUMN $column TYPE $newtype " ); |
| 6419 |
|
} |
| 6420 |
|
|
| 6421 |
|
/** |
| 6422 |
|
* @see QueryWriter::addUniqueIndex |