In my logs, I found below errors.

These always happened when a cron is executed.

Not sure if is it a problem of rules or Drupal cache. make a report here.

PDOException: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'rules_empty_sets' for key 'PRIMARY': INSERT INTO {variable} (name, value) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1); Array ( [:db_insert_placeholder_0] => rules_empty_sets [:db_insert_placeholder_1] => a:91:{s:29:"commerce_cart_product_prepare";i:0;s:35:"commerce_payment_order_paid_in_full";i:1;s:32:"commerce_shipping_calculate_rate";i:2;s:11:"bean_insert";i:3;s:11:"bean_update";i:4;s:12:"bean_presave";i:5;s:11:"bean_delete";i:6;s:9:"bean_view";i:7;s:22:"commerce_coupon_insert";i:8;s:22:"commerce_coupon_update";i:9;s:23:"commerce_coupon_presave";i:10;s:22:"commerce_coupon_delete";i:11;s:27:"commerce_coupon_type_insert";i:12;s:27:"commerce_coupon_type_update";i:13;s:28:"commerce_coupon_type_presave";i:14;s:27:"commerce_coupon_type_delete";i:15;s:32:"commerce_customer_profile_insert";i:16;s:32:"commerce_customer_profile_update";i:17;s:33:"commerce_customer_profile_presave";i:18;s:32:"commerce_customer_profile_delete";i:19;s:30:"commerce_customer_profile_view";i:20;s:25:"commerce_line_item_insert";i:21;s:26:"commerce_line_item_presave";i:22;s:23:"commerce_line_item_view";i:23;s:21:"commerce_order_insert";i:24;s:22:"commerce_order_presave";i:25;s:21:"commerce_order_delete";i:26;s:19:"commerce_order_view";i:27;s:35:"commerce_payment_transaction_insert";i:28;s:35:"commerce_payment_transaction_update";i:29;s:36:"commerce_payment_transaction_presave";i:30;s:35:"commerce_payment_transaction_delete";i:31;s:33:"commerce_payment_transaction_view";i:32;s:23:"commerce_product_insert";i:33;s:24:"commerce_product_presave";i:34;s:23:"commerce_product_delete";i:35;s:21:"commerce_product_view";i:36;s:28:"field_collection_item_insert";i:37;s:28:"field_collection_item_update";i:38;s:29:"field_collection_item_presave";i:39;s:28:"field_collection_item_delete";i:40;s:26:"field_collection_item_view";i:41;s:23:"flag_flagged_order_flag";i:42;s:25:"flag_unflagged_order_flag";i:43;s:22:"flag_flagged_bookmarks";i:44;s:24:"flag_unflagged_bookmarks";i:45;s:9:"node_view";i:46;s:11:"node_delete";i:47;s:4:"init";i:48;s:4:"cron";i:49;s:8:"watchdog";i:50;s:11:"user_update";i:51;s:12:"user_presave";i:52;s:9:"user_view";i:53;s:11:"user_delete";i:54;s:10:"user_login";i:55;s:11:"user_logout";i:56;s:20:"taxonomy_term_insert";i:57;s:20:"taxonomy_term_update";i:58;s:21:"taxonomy_term_presave";i:59;s:20:"taxonomy_term_delete";i:60;s:26:"taxonomy_vocabulary_insert";i:61;s:26:"taxonomy_vocabulary_update";i:62;s:27:"taxonomy_vocabulary_presave";i:63;s:26:"taxonomy_vocabulary_delete";i:64;s:45:"rules_forms_wine_product_node_form_form_built";i:65;s:46:"rules_forms_wine_product_node_form_form_submit";i:66;s:72:"rules_forms_wine_product_node_form_button_submit_actions_submit_validate";i:67;s:70:"rules_forms_wine_product_node_form_button_submit_actions_submit_submit";i:68;s:73:"rules_forms_wine_product_node_form_button_submit_actions_preview_validate";i:69;s:71:"rules_forms_wine_product_node_form_button_submit_actions_preview_submit";i:70;s:96:"rules_forms_wine_product_node_form_button_submit_field_pdattr_image_und_0_upload_button_validate";i:71;s:94:"rules_forms_wine_product_node_form_button_submit_field_pdattr_image_und_0_upload_button_submit";i:72;s:96:"rules_forms_wine_product_node_form_button_submit_field_pdattr_image_und_0_remove_button_validate";i:73;s:94:"rules_forms_wine_product_node_form_button_submit_field_pdattr_image_und_0_remove_button_submit";i:74;s:100:"rules_forms_wine_product_node_form_button_submit_field_pdattr_grape_col_und_0_remove_button_validate";i:75;s:98:"rules_forms_wine_product_node_form_button_submit_field_pdattr_grape_col_und_0_remove_button_submit";i:76;s:93:"rules_forms_wine_product_node_form_button_submit_field_pdattr_grape_col_und_add_more_validate";i:77;s:91:"rules_forms_wine_product_node_form_button_submit_field_pdattr_grape_col_und_add_more_submit";i:78;s:95:"rules_forms_wine_product_node_form_button_submit_field_pdattr_rate_und_0_remove_button_validate";i:79;s:93:"rules_forms_wine_product_node_form_button_submit_field_pdattr_rate_und_0_remove_button_submit";i:80;s:88:"rules_forms_wine_product_node_form_button_submit_field_pdattr_rate_und_add_more_validate";i:81;s:86:"rules_forms_wine_product_node_form_button_submit_field_pdattr_rate_und_add_more_submit";i:82;s:97:"rules_forms_wine_product_node_form_button_submit_field_pdattr_winery_und_0_remove_button_validate";i:83;s:95:"rules_forms_wine_product_node_form_button_submit_field_pdattr_winery_und_0_remove_button_submit";i:84;s:90:"rules_forms_wine_product_node_form_button_submit_field_pdattr_winery_und_add_more_validate";i:85;s:88:"rules_forms_wine_product_node_form_button_submit_field_pdattr_winery_und_add_more_submit";i:86;s:99:"rules_forms_wine_product_node_form_button_submit_field_slideshow_image_und_0_upload_button_validate";i:87;s:97:"rules_forms_wine_product_node_form_button_submit_field_slideshow_image_und_0_upload_button_submit";i:88;s:99:"rules_forms_wine_product_node_form_button_submit_field_slideshow_image_und_0_remove_button_validate";i:89;s:97:"rules_forms_wine_product_node_form_button_submit_field_slideshow_image_und_0_remove_button_submit";i:90;} ) in variable_set() (line 972 of /var/www/m1ntcellars_svn/includes/bootstrap.inc).

Comments

SocialNicheGuru’s picture

i just got this too

ptmkenny’s picture

Status: Active » Postponed (maintainer needs more info)

This is not a reproducible error. See Tips for making a good issue report for more information.

Are you using Commerce Kickstart? What configuration do you have to make to get this error?

joelpittet’s picture

The latest dev seems to delete this extra variable for 'rules_empty_sets'. I upgraded to that, updated the db to remove it and reverted back to 7.x-2.2 and that PDOException no longer exists.

I had to revert because -dev was throwing this error:

Error: Class 'RulesEventHandlerEntityBundle' not found in /sites/all/modules/contrib/rules/modules/node.rules.inc,
line 135

Fatal error: Class 'RulesEventHandlerEntityBundle' not found in /sites/all/modules/contrib/rules/modules/node.rules.inc on line 135

Hope that helps you get past the PDOException at the very least...

Exploratus’s picture

I got this when I upgraded to DEV. Reverted back

rbrownell’s picture

Status: Postponed (maintainer needs more info) » Needs review

I had the same problem... I am not using the Commerce Kickstart installation file but I am using Drupal Commerce.

fago’s picture

Status: Needs review » Fixed

ad #3 Please be sure to run update.php - that should have updated your registry. If for some reason that did not work out for you, try registry rebuild module or enable/disable any module.

ad issue: This should be fixed with the latest dev version or 2.3, please upgrade.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

GrigoriuNicolae’s picture

I think that this message come from Search Api Db when cron runs

rv0’s picture

Not using Search api, Not using commerce
But I'm seeing this error

PDOException: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'rules_empty_sets' for key 'PRIMARY': INSERT INTO {variable} (name, value) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1); Array ( [:db_insert_placeholder_0] => rules_empty_sets [:db_insert_placeholder_1] => a:49:{s:14:"country_insert";i:0;s:14:"country_update";i:1;s:15:"country_presave";i:2;s:14:"country_delete";i:3;s:12:"country_view";i:4;s:20:"og_membership_insert";i:5;s:20:"og_membership_update";i:6;s:21:"og_membership_presave";i:7;s:20:"og_membership_delete";i:8;s:23:"flag_flagged_newsletter";i:9;s:25:"flag_unflagged_newsletter";i:10;s:19:"flag_flagged_attend";i:11;s:21:"flag_unflagged_attend";i:12;s:22:"flag_flagged_bookmarks";i:13;s:24:"flag_unflagged_bookmarks";i:14;s:16:"og_user_approved";i:15;s:15:"og_user_blocked";i:16;s:14:"og_user_delete";i:17;s:13:"og_role_grant";i:18;s:14:"og_role_revoke";i:19;s:25:"entity_translation_insert";i:20;s:25:"entity_translation_update";i:21;s:25:"entity_translation_delete";i:22;s:12:"node_presave";i:23;s:9:"node_view";i:24;s:11:"node_delete";i:25;s:4:"init";i:26;s:4:"cron";i:27;s:8:"watchdog";i:28;s:11:"user_insert";i:29;s:11:"user_update";i:30;s:12:"user_presave";i:31;s:9:"user_view";i:32;s:11:"user_delete";i:33;s:10:"user_login";i:34;s:11:"user_logout";i:35;s:14:"comment_insert";i:36;s:14:"comment_update";i:37;s:15:"comment_presave";i:38;s:12:"comment_view";i:39;s:14:"comment_delete";i:40;s:20:"taxonomy_term_insert";i:41;s:20:"taxonomy_term_update";i:42;s:21:"taxonomy_term_presave";i:43;s:20:"taxonomy_term_delete";i:44;s:26:"taxonomy_vocabulary_insert";i:45;s:26:"taxonomy_vocabulary_update";i:46;s:27:"taxonomy_vocabulary_presave";i:47;s:26:"taxonomy_vocabulary_delete";i:48;} ) in variable_set() (line 976 of /home/sites/default_www/includes/bootstrap.inc).
gianlucarossi’s picture

Up how to solve? i have the same error using drupal commerce kickstart 2.0

impara’s picture

I have the same error, but I'm not using commerce kickstart

violation: 1062 Duplicate entry 'rules_empty_sets' for key 'PRIMARY':
INSERT INTO {variable} (name, value) VALUES
(:db_insert_placeholder_0, :db_insert_placeholder_1); Array
(
    [:db_insert_placeholder_0] => rules_empty_sets
    [:db_insert_placeholder_1] =>
a:72:{s:10:"clone_node";i:0;s:12:"group_insert";i:1;s:12:"group_update";i:2;s:13:"group_presave";i:3;s:12:"group_delete";i:4;s:20:"og_membership_insert";i:5;s:20:"og_membership_update";i:6;s:21:"og_membership_presave";i:7;s:20:"og_membership_delete";i:8;s:15:"profile2_insert";i:9;s:15:"profile2_update";i:10;s:16:"profile2_presave";i:11;s:15:"profile2_delete";i:12;s:13:"profile2_view";i:13;s:20:"WorkflowState_insert";i:14;s:20:"WorkflowState_update";i:15;s:21:"WorkflowState_presave";i:16;s:20:"WorkflowState_delete";i:17;s:31:"WorkflowConfigTransition_insert";i:18;s:31:"WorkflowConfigTransition_update";i:19;s:32:"WorkflowConfigTransition_presave";i:20;s:31:"WorkflowConfigTransition_delete";i:21;s:25:"WorkflowTransition_insert";i:22;s:25:"WorkflowTransition_update";i:23;s:26:"WorkflowTransition_presave";i:24;s:25:"WorkflowTransition_delete";i:25;s:34:"WorkflowScheduledTransition_insert";i:26;s:34:"WorkflowScheduledTransition_update";i:27;s:35:"WorkflowScheduledTransition_presave";i:28;s:34:"WorkflowScheduledTransition_delete";i:29;s:22:"flag_flagged_bookmarks";i:30;s:24:"flag_unflagged_bookmarks";i:31;s:27:"menu_rules_menu_link_insert";i:32;s:27:"menu_rules_menu_link_update";i:33;s:27:"menu_rules_menu_link_delete";i:34;s:14:"og_user_insert";i:35;s:16:"og_user_approved";i:36;s:15:"og_user_blocked";i:37;s:14:"og_user_delete";i:38;s:15:"relation_insert";i:39;s:15:"relation_update";i:40;s:15:"relation_delete";i:41;s:52:"scheduler_new_node_is_scheduled_for_publishing_event";i:42;s:57:"scheduler_existing_node_is_scheduled_for_publishing_event";i:43;s:54:"scheduler_new_node_is_scheduled_for_unpublishing_event";i:44;s:59:"scheduler_existing_node_is_scheduled_for_unpublishing_event";i:45;s:39:"scheduler_node_has_been_published_event";i:46;s:41:"scheduler_node_has_been_unpublished_event";i:47;s:32:"simplenews_rules_event_subscribe";i:48;s:34:"simplenews_rules_event_unsubscribe";i:49;s:12:"node_presave";i:50;s:9:"node_view";i:51;s:4:"init";i:52;s:4:"cron";i:53;s:8:"watchdog";i:54;s:11:"user_insert";i:55;s:11:"user_update";i:56;s:12:"user_presave";i:57;s:9:"user_view";i:58;s:11:"user_delete";i:59;s:10:"user_login";i:60;s:11:"user_logout";i:61;s:15:"comment_presave";i:62;s:12:"comment_view";i:63;s:20:"taxonomy_term_insert";i:64;s:20:"taxonomy_term_update";i:65;s:21:"taxonomy_term_presave";i:66;s:20:"taxonomy_term_delete";i:67;s:26:"taxonomy_vocabulary_insert";i:68;s:26:"taxonomy_vocabulary_update";i:69;s:27:"taxonomy_vocabulary_presave";i:70;s:26:"taxonomy_vocabulary_delete";i:71;}
)