Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Truncate.php

function Truncate::__toString

Same name in this branch
  1. 11.1.x core/lib/Drupal/Core/Database/Query/Truncate.php \Drupal\Core\Database\Query\Truncate::__toString()

Overrides Truncate::__toString

File

core/modules/sqlite/src/Driver/Database/sqlite/Truncate.php, line 15

Class

Truncate
SQLite implementation of \Drupal\Core\Database\Query\Truncate.

Namespace

Drupal\sqlite\Driver\Database\sqlite

Code

public function __toString() {
    // Create a sanitized comment string to prepend to the query.
    $comments = $this->connection
        ->makeComment($this->comments);
    return $comments . 'DELETE FROM {' . $this->connection
        ->escapeTable($this->table) . '} ';
}
RSS feed
Powered by Drupal