mstokes
10-19-2015, 05:49 AM
This is just a note for others who have had problems with missing attachments after upgrading from version 3.8 to 4.2.3.
It seems during the move of the attachments from vb_attachments table to vb_filedata in the upgrade steps in 4.0.0, a new column gets added called refcount but it is never populated.
Then, in 4.2.3 VB fixed a bug in a cleanup task that uses this column to determine whether an attachment is orphaned. Because none of the version 3 upgraded attachments had this column populated, the cleanup task removed ALL attachments.
Solution : Upgrade to any version less then 4.2.3 and update this column to make refcount = 1 using a SQL tool, then upgrade to 4.2.3.
It seems during the move of the attachments from vb_attachments table to vb_filedata in the upgrade steps in 4.0.0, a new column gets added called refcount but it is never populated.
Then, in 4.2.3 VB fixed a bug in a cleanup task that uses this column to determine whether an attachment is orphaned. Because none of the version 3 upgraded attachments had this column populated, the cleanup task removed ALL attachments.
Solution : Upgrade to any version less then 4.2.3 and update this column to make refcount = 1 using a SQL tool, then upgrade to 4.2.3.