title: Error: ORA-01428: argument '0' is out of range
body: <p>I am trying to calculate information gain in SQL. Below is my table:</p>
  
  <p><code>WORD, INSCALE NOTINSCALE D_FREQ
   book    22        19        41
   reserve 14        16        30</code></p>
  
  <p>The query is here:</p>
  
  <pre><code>CREATE TABLE FINAL_2INFOGAIN (WORD, INFO_G) AS
  SELECT WORD, 
  -(17081/33676)*LOG(10,17081/33676)+(D_FREQ/33676)*(INSCALE/D_FREQ)*log(10, INSCALE/D_FREQ)+(NOTINSCALE/33676)*(NOTINSCALE/D_FREQ)*log(10, NOTINSCALE/D_FREQ) AS INFO_G
  FROM FINAL_CONTIN2;
  </code></pre>
  
  <p>It keeps giving me this error: </p>
  
  <blockquote>
    <p>Error: ORA-01428: argument '0' is out of range
    01428. 00000 -  "argument '%s' is out of range"'. </p>
  </blockquote>
  
  <p>The error points to 'D_FREQ' at <code>log(10, NOTINSCALE/D_FREQ)</code>. </p>
  
  <p>Can anyone help me figure this out? Thanks.</p>