@Override
	public void deleteProduct(Product product) throws SQLException {
		Session session=null;
		try{
			session=HibernateUtil.getSessionFactory().openSession();
			session.beginTransaction();
			session.delete(product);
			session.getTransaction().commit();
		}catch(Exception e){
			e.printStackTrace();
		}finally{
			if(session!=null && session.isOpen())
				session.close();
		}
	}