实现查询条件多个值的或的关系 Select Id,Name from CustTable where CharIndex( CustTable.Name, 'ACDE,BEX,CCC')>0 CustTable.Name = 'ACDE' Or CustTable.Name = 'BEX' Or CustTable.Name = 'CCC'…
//list=list.OrderBy(ee => SqlFunctions.CharIndex("书记,主任,支部委员,村委委员,系统工作人员", ee.ZhiWu)).ToList(); //linq to sql中报错:只能在linq to entities中调用此方法. int i = 0; list = list.OrderBy(ee => { i=Array.IndexOf(new string[] { "书记", &…