title: SQL find rows with key specified in list, C#
body: <p>I want to make a sql query in C# that finds all rows with a key that is specified in a list. Can I do this with one query? I suppose that is much more efficent than my solution which finds one item at the time inside a for loop, se below:</p>
  
  <pre><code>foreach (int i in list)
  {
      string Q = "... where pk = " + i.ToString();
      using (SqlCommand CM = new SqlCommand(Q, C))
      {
           using (SqlDataReader R = CM.ExecuteReader())
           {
                while (R.Read())
                {
                    ...
                }
            }
       }
  }
  </code></pre>
  
  <p>list contains different in values.</p>
  
  <p>Thanks in advance!</p>