title: Creating and looping through a list in an sql server stored procedure
body: <p>Is there a way to declare a list of items in an sql server stored procedure using T-SQL and then loop through the items?</p>
  
  <p>I'm trying to do something like this:</p>
  
  <pre><code>input_string = 'my dog has fleas.'
  list_remove = 'a', 'e', 'i', 'o', 'u'
  
  for each item in list remove
      input_string = replace(input_string, item, '')
  end
  </code></pre>
  
  <p>And in the end input_string would be 'my dg hs fls.'</p>
  
  <p>I know we can create a table in a stored procedure.  Is that the best way to do something like this?</p>