I get this error message whenever I try to Delete a node/post from my site "PDOException: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'tohbad.flag_content' doesn't exist: DELETE FROM {flag_content} WHERE (content_type = :db_condition_placeholder_0) AND (content_id IN (:db_condition_placeholder_1, :db_condition_placeholder_2)) ; Array ( [:db_condition_placeholder_0] => heartbeat_activity [:db_condition_placeholder_1] => 39 [:db_condition_placeholder_2] => 40 ) in HeartbeatFlagPlugin->activityRemoved() (line 106 of C:\Users\dray\Desktop\Tohbad site\sites\all\modules\heartbeat\modules\heartbeat_plugins\includes\heartbeatflagplugin.inc)." Please can someone help me find a solution? thanks in advance
Comment | File | Size | Author |
---|---|---|---|
#14 | heartbeat-error_when_trying_to_delete_node-2063519-14-D7.patch | 3.52 KB | Nhungnb |
#12 | node-delete-fix-2063519-12.patch | 3.51 KB | veronicaSeveryn |
#8 | node-delete-fix-2063519-8.patch | 2.06 KB | Pravin Ajaaz |
Comments
Comment #1
RaphaelBriskie CreditAttribution: RaphaelBriskie commentedI'm getting the exact same error message, did you have any luck with it?
Comment #2
RaphaelBriskie CreditAttribution: RaphaelBriskie commentedComment #3
RaphaelBriskie CreditAttribution: RaphaelBriskie commentedTo elaborate a little, it prevents the node from being deleted at all.
Comment #4
kevinquillen CreditAttribution: kevinquillen commentedThis is because in Flag 3.x the flag_content table was renamed to flagging. I just ran into this same error. It does not appear that Heartbeat is equipped to work with Flag 3.x.
You will want to amend (and perhaps post a patch) the HeartbeatFlagPlugin class, and change instances of flag_content to flagging and ensure any Heartbeat queries using flag_content respect the new table field names.
I tracked this down via this post indicating the change: https://www.drupal.org/node/1870300#comment-7524067
Comment #5
jackman CreditAttribution: jackman commentedhi, i had the same error, but with statuses module, so guiding myself with kevinquillen info at the other post, i found that by replacing {flag_content} to {flagging}, {flag_content} to {entity_type}, {content_type} to {entity_type} and {content_id} to {entity_id} on heartbeatflagplugin.inc (in your case) you must disable that error, i wish you can solve it with this info
Comment #6
blur702I had this same issue with a fresh install of all referenced modules. To fix the problem I changed the following in heartbeatflagplugin.inc:
Changed all instanced in the file from {flag_content} to {flagging}
Changed all instanced in the file from {content_type} to {entity_type}
Changed all instanced in the file from {content_id} to {entity_id}
This seems to have fixed the problem, for now.
Comment #7
raul_drupal_dev CreditAttribution: raul_drupal_dev at Microblau / Colt commentedblur702 it's working for me! can you please report a patch??
Thanks!
Comment #8
Pravin Ajaaz CreditAttribution: Pravin Ajaaz commentedHere is the patch to fix this
Comment #9
Pravin Ajaaz CreditAttribution: Pravin Ajaaz commentedComment #10
Pravin Ajaaz CreditAttribution: Pravin Ajaaz at Ameex-Drupal Geeks commentedComment #11
liquidcms CreditAttribution: liquidcms commentedpatch works for me.
last post over a year ago; reasonable to assume this module is no longer being maintained?
Comment #12
veronicaSeveryn CreditAttribution: veronicaSeveryn at Inclind Inc commentedI am using Heartbeat 1.1.0 and Flag 3.9.0 and I was checking the code in Heartbeat based on the patch in #8.
I feel like there're a few more places where a change needs to be implemented. Revised patch attached.
Comment #13
delacosta456 CreditAttribution: delacosta456 commentedhi
both two patch DOES NOT worked for me.
However this patch, for flag plugin on this issue ,https://www.drupal.org/node/2102743 also solve the deleting problem here.. (for me)
Comment #14
Nhungnb CreditAttribution: Nhungnb as a volunteer commentedHere is the patch to fix this