title: Converting CLOB to NUMBER to compare - Oracle
body: <p>I'm newbie to oracle and my question is easy, is possible to convert a CLOB field into NUMBER type to do a comparison.</p>
  
  <p>I´ve tried using CAST and also with TO_NUMBER function but i did not get nothing working.</p>
  
  <p>My attempts:</p>
  
  <pre><code>WHERE TO_NUMBER(clob_field) = 100 -&gt; Error ORA-01722: NOT a valid number
  
  WHERE CAST(clob_field as NUMBER) = 100 -&gt; Error ORA-00932:Inconsistent datatypes
  </code></pre>
  
  <p>If this is not possible, which would be the best approach to do this?</p>
  
  <p>Thanks for your time and help.</p>