public void getProc1(String ob) {
Session session = getHibernateTemplate().getSessionFactory().getCurrentSession();
session = this.getHibernateTemplate().getSessionFactory().openSession();
CallableStatement cs = null;
try {
cs=session.connection().prepareCall("{Call test_xg_p3(?,?)}");
cs.setInt(1, 78);
cs.registerOutParameter(2, Types.VARCHAR);
cs.execute();
System.out.println(cs.getString(2));
} catch (HibernateException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
Session session = getHibernateTemplate().getSessionFactory().getCurrentSession();
session = this.getHibernateTemplate().getSessionFactory().openSession();
CallableStatement cs = null;
try {
cs=session.connection().prepareCall("{Call test_xg_p3(?,?)}");
cs.setInt(1, 78);
cs.registerOutParameter(2, Types.VARCHAR);
cs.execute();
System.out.println(cs.getString(2));
} catch (HibernateException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}