For example. This table, I want to search items taged with 'c', not with 'c#' or 'c++'. Tags are seperated by a space.
ID | BookName | Tags
1 | C++ Primer | c++
2 | .NET Core 3.1 Tutorial | c# .net
3 | Beginner Tutorial | c c# c++
Each book record can be marked with multiple tags, If I use
dbContext.Book.Where(a => a.Tags.Contains("c")).ToList()
I'll get all of them. But I only want get Beginner Tutorial.
Since I can not use =
to filter the Tag field. How can I solve this?
PS: I can not change the structure of this table, either.