You are here

protected function DatabaseSchema_sqlite::createKeySql in Drupal 7

Build the SQL expression for keys.

2 calls to DatabaseSchema_sqlite::createKeySql()
DatabaseSchema_sqlite::createColumsSql in includes/database/sqlite/schema.inc
Build the SQL expression for creating columns.
DatabaseSchema_sqlite::createIndexSql in includes/database/sqlite/schema.inc
Build the SQL expression for indexes.

File

includes/database/sqlite/schema.inc, line 95
Database schema code for SQLite databases.

Class

DatabaseSchema_sqlite

Code

protected function createKeySql($fields) {
  $return = array();
  foreach ($fields as $field) {
    if (is_array($field)) {
      $return[] = $field[0];
    }
    else {
      $return[] = $field;
    }
  }
  return implode(', ', $return);
}