I have a firstname and a lastname field. I'm writing a query to filter by a string. My query is something like this:
await this.prisma.person.findMany({
where: {
OR: [
{
firstname: {
contains: filterString
},
lastname: {
contains: filterString
},
},
],
},
});
If I try to search for "John" then it works, but doesn't work for "john doe" even if I have a firstname as John and lastname as Doe. Is there any way to concatenate these two fields within the query?