We know plenty about Data's career, even if it does leave a lot of holes. Starfleet Academy 2341-2345, where he struggled socially, being pranked on or outcast etc... I can see this happening to him in his early career too. They almost didn't let him in.
Major areas of study, were probability mechanics & exobiology. He was likely an excellent science officer for a long time, wherein the command track was not even an option. He served in some capacity aboard the USS Trieste. Spent 3 years as an ensign, & 12 as a lieutenant, before being promoted to Lt. Cmdr in 2360. By 2368 he'd encountered 1,754 non-human races, & been awarded 5 different citations, or medals, some of the UFP's highest.
Nothing is known about how he got them, & it's entirely possible they were all awarded for the same act. So in order to reconcile Data's apparent awkwardness in relating to crewmates, after 19 years in Starfleet, even as the 2nd officer of the UFP flagship, I see it like this...
You don't often spend 12 years as a lieutenant, & then they just decide you should be promoted, least of all if you're some weirdo science geek, no one can relate to. Something had to happen in 2360 to get him promoted, after years of seclusion, stored away in some starship or star base's labs. I like to think it was something so magnificent it also got him awarded 5 different medals for valor, gallantry, heroism, above & beyond the call of duty, at risk to his own life etc... He probably single-handedly saved an entire outpost brilliantly or something, thousands or maybe even millions of lives saved. He's certainly capable of that, all on his own, while his entire crew was incapacitated or something.
It was probably a media event that made him somewhat famous in the fleet, enough that it caught Picard's attention, & knowing what we know about how Picard operates, giving people chances that others might not, Worf, Sito Jax, Ro Laren, etc... Picard takes a lot of risks with who he selects, his best friend's widow as his CMO, & even making her son an acting ensign. Why should Data have been different?
After showing up on everyone's radar, Picard probably looked at the guy & thought "No one's ever going to give this guy the chance I think he deserves.", & then he took a leap & made the guy his 2nd officer, just like he took Riker as his XO, even though that guy should've been commanding his own ship by then, because he certainly wasn't a captain's "yes man". He took an XO who ought to be a captain, & a 2nd officer, who'd probably never really commanded people, so he could tutor him... & that's exactly what he did
It's a stretch to think Data might not have had much socialization before Enterprise, but it can be sussed out, & if you think of it as being a later career flash phenomenon that advanced him finally, like I'm thinking, it also leaves room for some people to still look at him like's he not really deserving of personhood