When I updated to the latest version (7.x-1.1) and ran drush updatedb:

Apache Solr Attachments: PDOException:
SQLSTATE[42S22]: Column not found: 1054 Unknown
column 'body' in 'where clause': DELETE FROM
{apachesolr_index_entities} 
WHERE  (entity_type = :db_condition_placeholder_0)
AND (body IS NULL ) ; Array
(
    [:db_condition_placeholder_0] => file
)
 in apachesolr_attachments_solr_reindex() (line 179
of
sites/all/modules/apachesolr_attachments/apachesolr_attachments.module).
CommentFileSizeAuthor
#3 1672768-3.patch1.09 KBnick_vh
#2 1672768-2.patch1.09 KBnick_vh

Comments

nick_vh’s picture

Can you tell me from what version you updated from? Can't seem to see the particular error in code. Does the same error occur when you install from scratch?

nick_vh’s picture

Status: Active » Needs review
StatusFileSize
new1.09 KB

this patch should fix it..

nick_vh’s picture

StatusFileSize
new1.09 KB

adding a newline

nick_vh’s picture

Status: Needs review » Fixed

Committed. Thanks for reporting!

pjcdawkins’s picture

Status: Fixed » Needs review

It was in upgrading from 7.x-1.0 to 7.x-1.1. I de-installed and re-installed, but obviously I could only do that because my attachments index was expendable (I hadn't really used it). So not quite so easy to test your patch now, sorry, I'll do so at the weekend if I have time.

pjcdawkins’s picture

Status: Needs review » Fixed

Sorry, I didn't mean to change the status (race condition!)

nick_vh’s picture

No problem :-)

I was able to replicate the problem and the above committed patch solved it for me. Hopefully it solved it for everyone!

Status: Fixed » Closed (fixed)

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