Incompetent character turns out to originally be very good at their job.
The Office: Michael is generally never portrayed as capable in anything. But in one episode you get a glimps at how he used to be a pretty good salesman who is great at making rapport with his clients and understands their concerns and needs and is able to effectively use this to close tough sales.
Brooklyn 99: Hitchcock and Scully are the precinct laughing stock. More adept at investigating pie origins than solving crimes. In a flashback it turned out they were hotshots back in the day, but they admit they dialed that way back so they can take it easy until retirement.