title: Regular Expression to Match All Comments in a T-SQL Script
body: <p>I need a Regular Expression to capture ALL comments in a block of T-SQL.  The Expression will need to work with the .Net Regex Class.</p>
  
  <p>Let's say I have the following T-SQL:</p>
  
  <pre><code>-- This is Comment 1
  SELECT Foo FROM Bar
  GO
  
  -- This is
  -- Comment 2
  UPDATE Bar SET Foo == 'Foo'
  GO
  
  /* This is Comment 3 */
  DELETE FROM Bar WHERE Foo = 'Foo'
  
  /* This is a
  multi-line comment */
  DROP TABLE Bar
  </code></pre>
  
  <p>I need to capture all of the comments, including the multi-line ones, so that I can strip them out.</p>
  
  <p><strong>EDIT: It would serve the same purpose to have an expression that takes everything BUT the comments.</strong></p>