title: Alternative to CONTAINS method?
body: <p>Giving the string below with "server type" separated by comma:</p>
  
  <p>string serverTypeList = "DB, IIS, CMDB";</p>
  
  <p>//server.Type in the loop below should have value of "MDB"</p>
  
  <p>My problem is that in this scenario it will return TRUE because "MDB" string is inside the serverTypeList.
  I need it to return TRUE only if it matches a type of "MDB" and not "CMDB":</p>
  
  <p>...</p>
  
  <pre><code>from site in SiteManager.Sites
  from server in site.Servers
  where
    serverTypeList.Contains(server.Type)
  select new Server()
  { ID=server.ID, SiteName=site.Name }
  </code></pre>
  
  <p>...</p>
  
  <p>How can I change the code above?</p>
  
  <p>Thank you</p>