Glamorgan captain Jim Allenby said his record opening partnership with Jacques Rudolph against Middlesex would have meant nothing if the team lost.
Allenby finished on 105 after he and Rudolph put on 136 - a T20 blast record - as Glamorgan won with just three balls to spare.
He said: "You don't play the game for records, you play for wins and it would have meant nothing in a loss."
Glamorgan chased down Middlesex's 184-3 to win with 187-4 in Richmond.
It was Allenby's first Twenty20 century for Glamorgan and only the third century scored in this year's T20 competition.
Glamorgan have moved to fourth in the T20 Blast South Group ahead of Friday evening's home match against Somerset.
Allenby said: "We needed to win a game, we've gone three or four games without a win; it was an absolute belter of a pitch, it had a very quick outfield. Jacques and I got on a bit of a roll and just kept going.
"Personally, it was great to get the runs, but we needed the win so we needed someone to step up and Jacques and I did today."
Glamorgan remain in quarter-final contention thanks to their fourth win in nine games.
Middlesex remain bottom after just one win in 11 games.