contains in linq query

前端 未结 4 398
青春惊慌失措
青春惊慌失措 2021-01-16 01:59

Hi i am using entity framework and LinQ. I have a table objects called users . i have a list called userids. i have to find all users where ids contains in the string. I hav

4条回答
  •  北恋
    北恋 (楼主)
    2021-01-16 02:38

    Put periods instead of commas.

    Try

    var u = context.users.Where(o=> usersid.Contains(o=> o.userid)).Select(o=> o);
    

提交回复
热议问题