title: Get a number from a sql string range
body: <p>I have a column of data that contains a percentage range as a string that I'd like to convert to a number so I can do easy comparisons.</p>
  
  <p>Possible values in the string:</p>
  
  <pre><code>'&lt;5%'
  '5-10%'
  '10-15%'
  ...
  '95-100%'
  </code></pre>
  
  <p>I'd like to convert this in my select where clause to just the first number, 5, 10, 15, etc. so that I can compare that value to a passed in "at least this" value.</p>
  
  <p>I've tried a bunch of variations on substring, charindex, convert, and replace, but I still can't seem to get something that works in all combinations.</p>
  
  <p>Any ideas?</p>