Success is an accomplishment of a task that was set before you. But not always will a person be able to accomplish that task and that counts as a failure. It can lead to depression if these failures are frequent. The self confidence drops and motivation also reduces since the person does not believe he can do it. But if you want to achieve success you require a drive, motivation and loads of self confidence to do so. The difference between both is amount of effort that is being put into the work. If its less then success will avoid you but if hard work is done then success is surely to follow. To achieve success one needs to drive himself to attain it. Failures in life will keep coming and if one can go past it then he is surely going to reach new heights.
So if the desire exists then success will come but if its a work done in vain then success will never come. So do what you do with maximum effort and achieve success in it.