$\Xc$ is a family of semi-martingales. Existence and uniqueness of solution of problem (\[optimdyn\]) is then proved. The optimal solution characterization is obtained from a dual formulation under minimal assumptions on the objective function.\
In this paper, we study the dual value function by a PDE approach. The dual problem appears as a mixed control/singular optimization problem with dynamics $(Y_t=Z_t D_t,\,t\in [0,T])$ governed by a classical control term $Z$ which comes from the insurance strategy and a singular term $D$ which comes from the state constraint.\
The originality of this paper is to study a stochastic control problem with state constraint. The wealth of the investor must be non-negative even after a jump. The duality method is not another alternative to solve this problem. In fact the primal problem leads to a HJB equation with boundary conditions. Because of the state space constraints these boundary conditions are not obvious to obtain. However, these delicate boundary conditions disappear in the dual problem. The regularity of the dual value function is not obvious to obtain. This explains the use of the notion of discontinuous viscosity solutions. The comparison theorem is not proved in a general framework since the operator which appears in 