表:用户
| user_Id | my_threads |
| 100 | 200:1, 201:2, 217:4 |
| 101 | 200:1, 215:3, 217:4 |
表:螺纹
| thread_id | author_id | title |
| 217 | 100 | This is title thread |
| 200 | 101 | this is only test |
当用户登录成功 $userId=user_Id 时,显示该用户线程的标题?
select title
from thread
where FIND_IN_SET(thread.thread_id,(select my_threads from user where user_id=100));
当 my_threads 没有像这样的冒号 200、217 时,上面的这个 sql 有效