Vergleich inc/db_mysql.php - 1.8.17 - 1.8.20

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 1353Zeile 1353
	 */
function drop_column($table, $column)
{

	 */
function drop_column($table, $column)
{

		return $this->write_query("ALTER TABLE {$this->table_prefix}{$table} DROP {$column}");



		$column = trim($column, '`');

return $this->write_query("ALTER TABLE {$this->table_prefix}{$table} DROP `{$column}`");

	}

/**
* Adds a column

	}

/**
* Adds a column

	 *

	 *

	 * @param string $table The table
* @param string $column The column name
* @param string $definition the new column definition

	 * @param string $table The table
* @param string $column The column name
* @param string $definition the new column definition

	 * @return resource
*/

	 * @return resource
*/

	function add_column($table, $column, $definition)

	function add_column($table, $column, $definition)

	{
return $this->write_query("ALTER TABLE {$this->table_prefix}{$table} ADD {$column} {$definition}");
}




	{
$column = trim($column, '`');

return $this->write_query("ALTER TABLE {$this->table_prefix}{$table} ADD `{$column}` {$definition}");
}


	/**
* Modifies a column
*

	/**
* Modifies a column
*

Zeile 1378Zeile 1382
	 * @return resource
*/
function modify_column($table, $column, $new_definition)

	 * @return resource
*/
function modify_column($table, $column, $new_definition)

	{
return $this->write_query("ALTER TABLE {$this->table_prefix}{$table} MODIFY {$column} {$new_definition}");



	{
$column = trim($column, '`');

return $this->write_query("ALTER TABLE {$this->table_prefix}{$table} MODIFY `{$column}` {$new_definition}");

	}

/**

	}

/**

Zeile 1393Zeile 1399
	 */
function rename_column($table, $old_column, $new_column, $new_definition)
{

	 */
function rename_column($table, $old_column, $new_column, $new_definition)
{

		return $this->write_query("ALTER TABLE {$this->table_prefix}{$table} CHANGE {$old_column} {$new_column} {$new_definition}");




		$old_column = trim($old_column, '`');
$new_column = trim($new_column, '`');

return $this->write_query("ALTER TABLE {$this->table_prefix}{$table} CHANGE `{$old_column}` `{$new_column}` {$new_definition}");

	}

/**

	}

/**