title: nested exception is java.sql.SQLException: Invalid column type
body: <p>I have to execute a query in my project,I have used jdbctemplate with MapSqlParameterSource to execute but mycode is giving following excpetion</p>
  
  <blockquote>
    <p>Exception ex : org.springframework.jdbc.UncategorizedSQLException: PreparedStatementCallback; uncategorized SQLException for SQL state [99999]; error code [17004]; Invalid column type; nested exception is java.sql.SQLException: Invalid column type</p>
  </blockquote>
  
  <p>My query is as mentioned below:</p>
  
  <pre><code>UPDATE INDS_GUEST_ACCOUNT_MST_TBL  SET
      ACTIVE_YN_FLG = :activeflag ,
      PASSWORD = (CASE WHEN :activeflag ='Y' THEN :password ELSE NULL END), 
      NOTES = (CASE WHEN :activeflag='Y' THEN :notes ELSE NULL END),
      COMPANY_NAME = (CASE WHEN :activeflag = 'Y' THEN :companyname ELSE NULL END),
      END_TIME = (CASE WHEN :activeflag='Y' THEN SYSTIMESTAMP+1 ELSE NULL END),
      UPDTD_ON_DT = SYSTIMESTAMP, UPDTD_BY_USR_ID = :user
  WHERE GA_SEQ = :sequence 
  </code></pre>
  
  <p>and the MapSqlParameterSource is like this :</p>
  
  <pre><code>MapSqlParameterSource paramSource = new MapSqlParameterSource();
  
  paramSource.addValue("activeflag", objGuestAccountInfo.getActiveflag().toUpperCase(), Types.VARCHAR);
  paramSource.addValue("password", objGuestAccountInfo.getPassword(), Types.VARCHAR);
  paramSource.addValue("notes", objGuestAccountInfo.getNotes(), Types.VARCHAR);
  paramSource.addValue("companyname", objGuestAccountInfo.getCompany(), Types.VARCHAR);
  paramSource.addValue("user", objGuestAccountInfo.getUser(), Types.VARCHAR);
  paramSource.addValue("sequence", objGuestAccountInfo.getGA_seq(), Types.NUMERIC);
  </code></pre>
  
  <p>My table structure is as follows:</p>
  
  <pre><code>GA_SEQ            NUMBER (6)
  PASSWORD          VARCHAR2 (60 Byte)
  END_TIME          DATE
  ACTIVE_YN_FLG     VARCHAR2 (1 Byte)
  NOTES             VARCHAR2 (4000 Byte)
  CREATD_BY_USR_ID  VARCHAR2 (30 Byte)
  CREATD_ON_DT      DATE
  UPDTD_BY_USR_ID   VARCHAR2 (30 Byte)
  UPDTD_ON_DT       DATE
  COMPANY_NAME      VARCHAR2 (50 Byte) 
  </code></pre>