South Australia 359 for December 5 (Hunt 162, McSweeney 112*) and 151 (Sandhu 4-31) won queensland 238 (Peirson 61, McAndrew 6-41) and 296 (Khawaja 114, Burns 91, McAndrew 3-60) by three runs
The final day was up and down, with the Redbacks leading from the start, then the home team, before a comeback from the visitors in the final session at the Gabba.
South Australia were bowled out early in the morning for 151, leaving the hosts 273 to win.
Queensland captain Khawaja, who came into the crease on 11 for 2, took his team to the brink of victory when he attacked Buckingham with over five overs on the remaining day with only four runs needed to win.
The tall pacer, who had previously proven costly against the Queensland batsmen, knocked down Khawaja’s leg stump.
“Unbelievable. Without a doubt, the best game of cricket I have ever been involved in. What a moment,” Buckingham said. “I kept fighting. I feel like one of my strengths is never giving up. The boys bowled absolutely brilliantly.
“[Khawaja] He is an international class player and he showed it today. He was exceptional.”
Khawaja had not played for Queensland in the Sheffield Shield for over a month due to Cricket Australia’s workload management policy.
The 36-year-old missed the Bulls’ last two Shield matches, and the break certainly didn’t hurt. He played an extraordinary shot off Buckingham for six that rose five meters off the ground like a tracer bullet into the stands. He also deployed a variety of exquisite late cuts from spinner Ben Manenti.
Burns couldn’t have batted better in what was a masterclass in shot selection and execution. A cover vehicle from Buckingham was shot to the limit. He drove, bowled and broke boundaries with panache in a knock that showed why he was Australia’s opener in 23 Tests.
Burns fell nine runs short of his century when he tickled Nathan McAndrew to wicketkeeper Harry Nielsen.
Queensland looked in control at 219 for 4 until Nathan McSweeney dismissed Jimmy Peirson and Michael Neser, both lbw.
All-rounder Jack Wildermuth was dismissed by a classic McAndrew legcutter with 28 runs required. Gurinder Sandhu hit a wild hit on Buckingham and the Redbacks went back on top. Mark Steketee pulled his wicket in the same direction as the pressure indicated.
Queensland needed 23 to win when last man Mitch Swepson came into the box and Khawaja almost took them home.
McAndrew, with nine wickets for the match, was South Australia’s hero.
“He is a serious player. He is highly valued within our group,” Buckingham said. “There’s no doubt that someday he’ll rock a baggy green suit.”