My last job was a big failure and hence I am very apprehensive about the next one

I am about to join a private firm. My last job was a big failure as everything that I did went the wrong way and hence I was thrown out. Now I am really apprehensive about this new job as well as my self confidence is very low. What to do in such a situation?