select substring_index(substring_index(a.unit_proj_type,',', b.help_topic_id + 1), ',', -1) as unit_proj_type from ucas_unit_proj a
JOIN mysql.help_topic b
ON b.help_topic_id < (LENGTH(a.unit_proj_type) - LENGTH(REPLACE(a.unit_proj_type, ',', '')) + 1 )
where a.unit_proj_type is not null
MySQL 将字符串根据逗号分隔,拆分为多条记录
最新推荐文章于 2024-06-26 13:05:08 发布