The paper deals with an investment problem with CVaR risk measure and mixed-integer value function which models the losses. Qualitative stability of the problem is studied and explicit formulas for the directional derivative of the optimal value function are derived.