title: nested exception is java.sql.SQLException: Invalid column name ORACLE
body: <p>I tried to execute the following oracle query using JdbcTemplate in Java:</p>
  
  <pre><code>select RESOURCE_ID 
  from REPRO_PRINTING_JOB 
  where (USER_ID=? and PRINTING_CENTER_ID=?) 
  group by RESOURCE_ID 
  union all 
  select RESOURCE_ID 
  from REPRO_PRINTING_JOB_OLD 
  where (USER_ID=? and PRINTING_CENTER_ID=? and STATE='CM') 
  group by RESOURCE_ID
  </code></pre>
  
  <p>The query is working perfectly in oracle query browser but its not working during the execution in java. What could be the source of this problem? I´ve heard something about Jdbc cannot handle case sensitive. Is this true?</p>
  
  <p>ADDED JAVA CODE(CORRECTED) :
  I call the query using getStatement() which retrieves the query from external source(a properties file) as belows :</p>
  
  <pre><code>   public List&lt;PrintingJob&gt; getPrintingJobsByCreatedUserId(String createdUserId, String userId) {
      if(log.isDebugEnabled()) {
          log.debug("getReportItemsByUserId(" + createdUserId + "," + userId + ")");
      }
      try {               
          System.out.println("getPrintingJobsByResourceId : createdUserId :"+createdUserId+",userId : "+userId);
          return getJdbcTemplate().query(getStatement("gen.report.userid"),                       
                  new Object[]{createdUserId, userId, createdUserId, userId},                     
                  new PrintingJobMapper());           
          } catch (DataAccessException ex) {              
              log.error("Error executing query: " + ex.getClass() + ":" + ex.getMessage());               
              return null;            
          }       
  }
  </code></pre>