public function dropColumn( $table, $name )
    {
        try
        {
            $tmpTable = $table . '_old';

            $this->startTransaction();

            $this->copyTable( $table, $tmpTable, [ $name ] );

            $this->dropTable( $tmpTable );

            $this->commitTransaction();
        }
        catch ( Exception $e )
        {
            $this->rollbackTransaction();

            return FALSE;
        }

        return TRUE;
    }
public function dropColumn( $table, $name )
    {
        try
        {
            $tmpTable = $table . '_old';

            $this->startTransaction();

            $this->copyTable( $table, $tmpTable, [ $name ] );

            $this->dropTable( $tmpTable );

            $this->commitTransaction();
        }
        catch ( Exception $e )
        {
            $this->rollbackTransaction();

            return FALSE;
        }

        return TRUE;
    }
public function dropColumn ( $ table , $ name ) { try { $ tmpTable = $ table . '_old' ; $ this -> startTransaction ( ) ; $ this -> copyTable ( $ table , $ tmpTable , [ $ name ] ) ; $ this -> dropTable ( $ tmpTable ) ; $ this -> commitTransaction ( ) ; } catch ( Exception $ e ) { $ this -> rollbackTransaction ( ) ; return FALSE ; } return TRUE ; }
Removes a column from a database table.

@param string $table table name
@param string $name  column name to drop

@return bool TRUE on success, FALSE on failure
Removes a column from a database table .