title: Create selectlist from list from another list
body: <p>I have two different models. A UsersInRoles model and a Users model.  Users can be in multiple roles, so in the UsersInRoles model it matches a userId with a RoleId.  What I need to do is get a selectList for all users in a particular role.  I have tried two different methods which both are not working.</p>
  
  <p>Here is the first method I tried:</p>
  
  <pre><code>var techs = new HashSet&lt;Guid&gt;(db.usersInRoles.Where(u =&gt; u.RoleId == new Guid(Properties.Settings.Default.TechID)).Select(u =&gt; u.UserId));
  ViewBag.SearchTechnician = new SelectList(db.Users.Where(u =&gt; u.UserId == techs.Contains&lt;userId&gt;).OrderBy(u =&gt; u.FirstName).ThenBy(u =&gt; u.LastName), "FullName", "FullName");
  </code></pre>
  
  <p>and I am getting an error on the .Contains that says:</p>
  
  <blockquote>
    <p>The type or namespace name could not be found (are you missing a using directive or an assembly reference)?</p>
  </blockquote>
  
  <p>The second method I have tried is:</p>
  
  <pre><code>ViewBag.SearchTechnician = new SelectList(from u in db.Users
                                            where u.UserId = (
                                            from ur in db.usersInRoles
                                            where ur.RoleId = new Guid(Properties.Settings.Default.TechID)
                                            select ur.UserId
                                            );
  </code></pre>
  
  <p>and I am receiving an error on the second where clause saying the following:</p>
  
  <p>cannot implicitly convert type System.Guid to bool</p>
  
  <p>Am I on the right track or I am completely down the wrong path?</p>