While (dbset. Next () {clob = (oracleresultset) dbset). getclob (1); clob. putstring (1, questioncontent );
Or
If (RSS. Next () {clob = (clob) RSS. getclob (1); clob. putstring (1, allmobilecode );}
If the connection pool is used for insertion, an error is returned. java. Lang. classcastexception: org. Apache. commons. DBCP. delegatingresultset (type conversion exception)
When you operate in JDBC mode, everything is normal. If you switch to the JNDI mode, Java appears. SQL. clob to Oracle. SQL. an error occurred while converting the clob type. I checked it online for half a day and finally found the following solution, which is very simple:
Delete the Oracle Driver (class12.jar) from the WEB-INF/lib directory of the current project, only put one copy in the common/lib in the Tomcat directory (here we need to leave one copy in Tomcat lib because driverclassname = "oracle. JDBC. driver. oracledriver ", the driver must exist when Tomcat is loaded, or an error will be reported ).