Duplicate entry error
mikeytown2 - April 25, 2009 - 20:20
| Project: | Restricted Search |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Description
Duplicate entry '426' for key 1 query: INSERT INTO search_block VALUES ('426', '0', '1') in /sites/all/modules/search_block/search_block.module on line 193.
#1
Related Info
http://drupal.org/node/270777#comment-1519760
#2
#3
I get this error, without rules module.
I am using postgres 8.3.7.
I get this error, when I enable the module:
* warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "ON" LINE 2: ON DUPLICATE KEY UPDATE enabled=0, dirty=1 ^ in <SNIP>/includes/database.pgsql.inc on line 139.* user warning: query: INSERT INTO search_block (nid, enabled, dirty) VALUES ('1', '0', '1') ON DUPLICATE KEY UPDATE enabled=0, dirty=1 in <SNIP>/sites/all/modules/search_block/search_block.module on line 271.
* warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "ON" LINE 2: ON DUPLICATE KEY UPDATE enabled=0, dirty=1 ^ in <SNIP>/includes/database.pgsql.inc on line 139.
* user warning: query: INSERT INTO search_block (nid, enabled, dirty) VALUES ('2', '0', '1') ON DUPLICATE KEY UPDATE enabled=0, dirty=1 in <SNIP>/sites/all/modules/search_block/search_block.module on line 271.
I get a similar error, when saving a node, and on cron run. It's also not restricting search. The content-type doesn't show in "Advanced Search" but it still returns results that should be restricted.