In my Struts Action class, I invoke mysql¡¯ stored function, but get following error: javax.servlet.ServletException: For input string: ¡°20) CHARSET latin1 READS SQL DATA ¡ java.lang.NumberFormatException: For input string: ¡°20) CHARSET latin1 Source code: ¡ Struts Action.class ¡ String result; Connection con; CallableStatement mf=con.prepareCall(¡°{?call sf_login_check(?)}¡±); mf.registerOutParameter(1,TypesVARCHAR); mf.setString(2,¡±test¡±); mf.execute(); result=mf.getString(1); ¡ Mysql stored function Create function sf_login_check(v_login_id varchar(10)) returns varchar(20) READS SQL DATA BEGIN; DECLARE t_exist INT; Select cout(*) into t_exist from accts Where id=v_loginid; If t_exist1 then Return(¡®Success¡¯); Else Return(¡®Fail¡¯); End if; END; Any clue? Tks in advance john
--------------------------------- Building a website is a piece of cake. Yahoo! Small Business gives you all the tools to get online.