Fixed discussion_type is varchar instead of varbinary, and may cause collation issues on join

Xon

Well-known member
Affected version
2.2.6 Patch 2
In XF2.2+, the new xf_thread_type.thread_type_id as varbinary. However the existing xf_thread.discussion_type table this is varchar.

Despite these columns being logically the same, joining from varbinary to varchar can cause and illegal mix of collations, but only on some installations which may make diagnosing harder than it needs to be.
 
We're going to defer this until 2.3 for fear that this could be a significant alter for some databases.

Anyone who needs to run this now can do so safely with the following query:

SQL:
ALTER TABLE `xf_thread`
MODIFY COLUMN `discussion_type` VARBINARY(50) NOT NULL DEFAULT ''
 
Top Bottom