title: Is there a difference between calling BeginTransaction from the SQLConnection object or from the SqlCommand object?
body: <p>So I have this sql from c# to insert purchase info into a table (sql server 2005), and purchase items (multiple) into another table. </p>
  
  <p>I would like the 2 insert statements to be run in a transaction by calling BeginTransaction.</p>
  
  <p>I notice that I can do it either from the SqlConnection object or SqlCommand object. My guts tells me that I should do it through the connection object, as I will be using 1 command object for each insert, but they both share the same connection. </p>
  
  <p>Am I right?</p>
  
  <p>In general is there a difference between the two?</p>