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.
さて、「PersonName」を検索していて、「person」と入力すると、その人は見つかりませんが、「Person」は見つかります。私の入力に似たものを探すように指示する方法はありますか?
私はこのように単純に検索を行っています:
$db->sqlquery(" SELECT `user_id` FROM `users` WHERE `username`LIKE ?", array("%$user%"));
これは、フィールドの照合に依存します。
照合が_csで終了する場合は大文字と小文字が区別され、_ciが終了する場合は大文字と小文字が区別されません。
フィールドのプロパティを変更すると、インデックス/検索が続きます。
クエリで LIKE ではなく ILIKE を試してみませんか?