title: How to compare a NUMBER with VARCHAR2 type number having leading zeroes?
body: <p>I am trying to compare two columns in two different tables in a database. One column is of type VARCHAR2(4 CHAR) and the other is of type DECIMAL. Although I am pulling these columns into JAVA as a string to do the comparison, I am running into this issue:</p>
  
  <p>Elements in column (decimal) are: 123, 456, 789</p>
  
  <p>Elements of compared column (varchar) are: 0123, 0456, 0789</p>
  
  <p>So I want to know if there is a way that I can remove this prefixed 0 as I am pulling it from the database (like some sort of TRIM0()) such that elements from both columns would be the same?</p>
  
  <p>I am trying to avoid handling this column in the JAVA itself to improve performance.</p>