function TruncateQuery::__construct
Constructs a TruncateQuery object.
Parameters
DatabaseConnection $connection: A DatabaseConnection object.
string $table: Name of the table to associate with this query.
array $options: Array of database options.
Overrides Query::__construct
File
-
includes/
database/ query.inc, line 912
Class
- TruncateQuery
- General class for an abstracted TRUNCATE operation.
Code
public function __construct(DatabaseConnection $connection, $table, array $options = array()) {
$options['return'] = Database::RETURN_AFFECTED;
parent::__construct($connection, $options);
$this->table = $table;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.