title: Using regexp_like in Oracle to match on multiple string conditions using a range of values
body: <p>I have a field in my Oracle DB that contains codes and from this I need to pull multiple values using a range of values.</p>
  <p>As an example I need to pull all codes in the range <code>C00.0 - C39.9</code> i.e. begins with C, the second character can be 0-3, third character is 0-9, followed by a &quot;.&quot; and then the last digit is 0-9 e.g.</p>
  <pre><code>CODES
  -----
  C00.0
  C10.4
  C15.8
  C39.8
  </code></pre>
  <p>The example above is for one pattern, I have multiple patterns to match on, here is another example</p>
  <pre><code>C50.011-C69.92
  </code></pre>
  <p>Again, starts with C, second character is 5-6, third is 0-9, fourth is &quot;.&quot;, fifth is 0-9, sixth is 1-2 etc.</p>
  <p>I have tried the following but my pipe function doesn't appear to pick up the second condition and therefore I am only getting results for the first condition <code>'^[C][0-3][0-9][.][0-9]'</code>:</p>
  <pre><code>SELECT DISTINCT CODES
  FROM
  TABLE
  WHERE REGEXP_LIKE (CODES,   '^[C][0-3][0-9][.][0-9]|
                               ^[C][4][0-3][.][0-9]|
                               ^[C][4][A][.][0-9]|
                               ^[C][4][4-9][.][0-9]|
                               ^[C][4][9][.][A][0-9]|
                               ^[C][5-6][0-9][.][0-9][1-9]|
                               ^[C][7][0-5][.][0-9]|
                               ^[C][7][A-B][.][0-8]')
  ORDER BY CODES
  </code></pre>
  <p>I would be very grateful if anyone could make a suggestion on how I can pull the additional patterns.</p>