I was trying out the search in chapter 7 (CRUD Database Operations)
return Acronym.query(on: req).group(.or) { or in
// 2
or.filter(\.short == searchTerm)
// 3
or.filter(\.long == searchTerm)
// 4
}.all()
From what I can see, the search was case sensitive. I was running with SQLiteDatabase for this test. Is there a way to do it case insensitive. Searching for omg and not getting a hit for OMG seems a bit unusual. Does the db selected have anything to do with this or do I have to do something else for this to work?
@shades so I think you can use ~~ or ~ (canβt remember off the top of my head which one), which is the ILIKE command, which should translate to case-insensitive
Failing that, join the Vapor Discord server at http://vapor.team and ask there!