Thank you for taking the time to post this on the Xbox Forums. We understand that you are currently experiencing difficulties with being able to connect your Microsoft Account on Switch version of Minecraft.
If you are able to pull up that code, I will provide a link
here. This should allow you to sync up your account once more.
Additionally, if you are unable to provide favorable results this way, I recommend checking out the
Minecraft for Nintendo Switch FAQ as it should carry a similar link that should assist you with resolving this.
Give this a try and let us know if this works for you!