He’s not the father!!???

So my boyfriend or ex boyfriend I should say had a very rough nine months with me being in Orlando and him living in west palm beach. Our relationship wasn’t the best because I wasn’t always faithful... I swore that he was the father tho... I thought I had it all figured out.... well his mom got him a paternity test so we could find out. He sent the test in while we were still in the hospital. He sign the birth certificate... I even gave her his last name... about a week and a day later he gets the results and turns out he is not the father.... Words can’t begin to explain how I feel. I hate myself so much. And I feel so bad for my daughter.... she doesn’t deserve this... he walked out and made it very clear he was never gonna come back.... I’m so scared... I feel so confused . Idk anymore..