protected function copyTable( $table, $tempTable = '', array $exclude = [ ] )
    {
        $query = "ALTER TABLE $table RENAME TO $tempTable";

        $result = $this->modify( $query );

        if ( FALSE === $result )
        {
            throw new DatabaseException( 'Drop column failed' );
        }

        $columns = $this->getTableColumns( $tempTable, $exclude );

        // create table
        $this->createTable( $table, $columns );

        $this->copyTableData( $table, $tempTable, $columns );
    }