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

Breadcrumb

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

function Schema::prefixNonTable

Create names for indexes, primary keys and constraints.

This prevents using {} around non-table names like indexes and keys.

File

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

Class

Schema
Provides a base implementation for Database Schema.

Namespace

Drupal\Core\Database

Code

public function prefixNonTable($table) {
    $args = func_get_args();
    $info = $this->getPrefixInfo($table);
    $args[0] = $info['table'];
    return implode('_', $args);
}
RSS feed
Powered by Drupal