【发布时间】:2010-09-16 13:29:11
【问题描述】:
我正在尝试在 group_concat 命令中使用 concat_ws。使用查询,简化如下:
SELECT item.title, GROUP_CONCAT( CONCAT_WS( ',', attachments.id, attachments.type, attachments.name ) ) as attachments
FROM story AS item
LEFT OUTER JOIN story_attachment AS attachments ON item.id = attachments.item_id
GROUP BY item.id
我将附件列作为 Blob 类型。是否可以将其作为字符串而不是 Blob 获取?
【问题讨论】: