Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
この問題があります。
との1つのテーブル。
id | routename | usersid | 1 | route 1 | 1,2,3,5 2 | 2 | route 2 | 5,20,15 3 | 4 | route 4 | 10,15,7,5 |
私は必要です、ejを検索してください。userid 5 in colum usersid ... しかし、複数の行があるため、どうすればよいかわかりません。
FIND_IN_SET()を探しているかもしれません。
select * from Table1 WHERE FIND_IN_SET(5,usersid)
サンプルフィドル