That's different, they played later in the tournament. I'm referring to back to back matches.
OK, you asked and James gave you a fairly recent example; here’s one a month earlier. Qualie/1R : Barca’19 Granollers defeated Jarry in qualies but lost 1R, both in 3 sets.
Some others from a few years ago:
Ramos Vinolas beat Haase M-C’15 in qualies and 1R (straight sets both)
ARV was on the receiving side when Cuevas beat him at Valencia’10 in qualies and 1R (straight sets both)
Thiemo de Bakker retired in qualies vs Steven Diez but got in as a LL and beat Diez 1R Atlanta’14. I’m betting that was heat exhaustion because TdB won 1R very easily (1&2).
Elias Ymer and Nishioka split IW’17 qualies and 1R with the Japanese lefty advancing to 2R.