function Schema::dropField

Drop a field.

Parameters

$table: The table to be altered.

$field: The field to be dropped.

Return value

bool TRUE if the field was successfully dropped, FALSE if there was no field by that name to begin with.

4 methods override Schema::dropField()
Schema::dropField in core/modules/sqlite/src/Driver/Database/sqlite/Schema.php
Drop a field.
Schema::dropField in core/modules/mysql/src/Driver/Database/mysql/Schema.php
Drop a field.
Schema::dropField in core/modules/pgsql/src/Driver/Database/pgsql/Schema.php
Drop a field.
Schema::dropField in core/tests/fixtures/database_drivers/module/corefake/src/Driver/Database/corefakeWithAllCustomClasses/Schema.php
Drop a field.

File

core/lib/Drupal/Core/Database/Schema.php, line 347

Class

Schema
Provides a base implementation for Database Schema.

Namespace

Drupal\Core\Database

Code

abstract public function dropField($table, $field);

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.