- Issue created by @Vivek Panicker
Getting the following error when saving content with Automator enabled for a field:
Drupal\Core\Database\IntegrityConstraintViolationException: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '71-0-0-en' for key 'PRIMARY': INSERT INTO "node__field_product_specifications" ("entity_id", "revision_id", "bundle", "delta", "langcode", "field_product_specifications_value", "field_product_specifications_format") VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4, :db_insert_placeholder_5, :db_insert_placeholder_6); Array ( [:db_insert_placeholder_0] => 71 [:db_insert_placeholder_1] => 101 [:db_insert_placeholder_2] => product [:db_insert_placeholder_3] => 0 [:db_insert_placeholder_4] => en [:db_insert_placeholder_5] => The 50-Series is a high-performance, durable, and robust diesel engine designed for various heavy-duty applications. Specifications include the following: [:db_insert_placeholder_6] => content_format ) in Drupal\mysql\Driver\Database\mysql\ExceptionHandler->handleExecutionException() (line 45 of /var/www/html/web/core/modules/mysql/src/Driver/Database/mysql/ExceptionHandler.php).
Drupal\Core\Database\IntegrityConstraintViolationException: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '71-0-0-en' for key 'PRIMARY': INSERT INTO "node__field_product_specifications" ("entity_id", "revision_id", "bundle", "delta", "langcode", "field_product_specifications_value", "field_product_specifications_format") VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4, :db_insert_placeholder_5, :db_insert_placeholder_6); Array ( [:db_insert_placeholder_0] => 71 [:db_insert_placeholder_1] => 101 [:db_insert_placeholder_2] => product [:db_insert_placeholder_3] => 0 [:db_insert_placeholder_4] => en [:db_insert_placeholder_5] => The 50-Series is a high-performance, durable, and robust diesel engine designed for various heavy-duty applications. Specifications include the following: [:db_insert_placeholder_6] => content_format ) in Drupal\mysql\Driver\Database\mysql\ExceptionHandler->handleExecutionException() (line 45 of /var/www/html/web/core/modules/mysql/src/Driver/Database/mysql/ExceptionHandler.php).
- In Drupal CMS, create a content with Title and Specifications field.
- For Specifications, the field should be auto-populated with the value from the Title field.
- I am providing the title of a product from a company and have set the promp accordingly to consider the product of that company only.
- When the same title is provided twice, then the error appears.
NA
NA
NA
NA
NA
Active
1.0
Code