I am using spring 3.0 and MSSQL database, and am having a problem calling a stored procedure using SimpleJdbcCall. The stored procedure requires a parameter of type 'XML'.
I've tried this:
I always wind up with [#document: null] in the database.Code:public void setDataSource(DataSource dataSource) { this.updateDataProc = new SimpleJdbcCall(dataSource). withProcedureName("spUpdateProc"); this.createUserProc.declareParameters( new SqlParameter("ID", Types.INTEGER), new SqlParameter("XmlData", Types.SQLXML) ); ... public void updateData(int id, Document xmlDoc) { Map<String,Object> in = new HashMap<String,Object>(); in.put("ID", id); in.put("XmlData", xmlDoc ); this.updateGameConfigProc.execute(in); }
There is existing code (not using spring) that works fine, so I know the stored procedure itself is ok.
Help!


Reply With Quote