Search with Comma Separated value using Link Query in Entity Framework

on Jul 11, 2019 05:01 AM


i have linQ query i need to search databse with comma seperated values

valuein database as follows

Language Column

1 English

2 English, Persian, Spanish

3 English, Spanish

//this is the search criteria
language = "English, Persian";
q = q.Where(u => u.Languages.Contains(language));

on earch record 1 2 and 3 comes

if search criteria is language="Persian , Spanish"

so record 2 and 3 should come 

please advice

Download FREE API for Word, Excel and PDF in ASP.Net: Download