Tldr: rejected via "in a relationship "

I've only approached women less than a handful of times during the day and never while i am at the gym.

I would consider myself to be of average attractiveness as i have a strong athletic build, college athlete but i am under 5'8 which i know women have a tendancy for taller guys but that hasn't kept me from getting into relationshps(longest 2 years) and or hookups. body count is around 15 and i have slept with women taller than myself a couple of times(never serious relationships tho).

I would say i struggle with self confidence as i question whether or not I am attracitve at times which prevents me from going up to girls during the day. Fear of rejection definitely does affect me.

That being said i went up to a girl today in a new gym that i have beein going to recently and she rejected me.

The conversation went as follows:

me: Hey sorry i don't mean to bother you but i just wanted to say that I like your look

her: thank you

me: i was wondering if i could get your number?

her: Im in a relationship, sorry 😬

me: all good no worries 👍

walks away

I was definitely really nervous and im pretty sure i was visibly shaking(hopefully subtlely) and she could probably tell that i was nervous

Although i got rejected i am proud of myself for even going up to her in the first place and the relief i felt while walking away was nice it felt like there was weight lifted off of my shoulders