InsertTrait::$insertValues

Same name in other branches
  1. 9 core/lib/Drupal/Core/Database/Query/InsertTrait.php \Drupal\Core\Database\Query\InsertTrait::insertValues
  2. 10 core/lib/Drupal/Core/Database/Query/InsertTrait.php \Drupal\Core\Database\Query\InsertTrait::insertValues
  3. 11.x core/lib/Drupal/Core/Database/Query/InsertTrait.php \Drupal\Core\Database\Query\InsertTrait::insertValues

A nested array of values to insert.

$insertValues is an array of arrays. Each sub-array is either an associative array whose keys are field names and whose values are field values to insert, or a non-associative array of values in the same order as $insertFields.

Whether multiple insert sets will be run in a single query or multiple queries is left to individual drivers to implement in whatever manner is most appropriate. The order of values in each sub-array must match the order of fields in $insertFields.

Type: array

File

core/lib/Drupal/Core/Database/Query/InsertTrait.php, line 48

Class

InsertTrait
Provides common functionality for INSERT and UPSERT queries.

Namespace

Drupal\Core\Database\Query

Code

protected $insertValues = [];

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