The 8-1 chance was one of a number of contenders in touching distance of the lead at the two-furlong pole, and headed into a clear lead a furlong from home.
Favourite Sorelle Delle Rose tried to keep on terms with Harrington's charge, but Gymkhana would not be denied and boxed on well to score by three-quarters of a length.
The double started when The King showed the benefit of his debut fifth at the Curragh when bounding to victory in the Irish Stallion Farms EBF Maiden.
Newcomer Imaging looked to be getting on top of things when leading in the final furlong, but Shane Foley found another gear on Jessica Harrington's 7-2 chance and he streaked away to score by three and a quarter lengths.
Harrington said: "He was very good. He was very green and Shane said he got himself into a place he didn't want to be because they'd gone very steady, but he was good when he pulled him out.
"He really quickened up well, he quickened up like a good horse. He's going to be a nice staying horse.
"We've always thought he was nice and he is in the Irish Guineas and the Derby. He's got a few good entries. We've been waiting all year for him. He's won now and we'll wait and see."