Evan Williams' 10-year-old came down at the second-last when still leading in his bid to lift the Paddy Power Gold Cup for the second successive year last month.
Midnight Shadow took the spoils that day but Coole Cody (12/1) got his revenge in game fashion under Wedge.
He led at the second fence, galloped on strongly all the way and proved impossible to pass, crossing the line two lengths to the good.
Midnight Shadow met the penultimate fence wrong but he was still second until the dying strides where Zanza snatched the runner-up spot by a short head. Midnight Shadow was third with Fusil Raffles fourth.
Wedge said: "Once I got the front, he just starts taking me and enjoying it. He gallops and I knew he wouldn't lie down.
"It's a shame what happened the last day, but it was brilliant he's gone and done that today.
"Evan has done a fantastic job getting the horse's confidence back and getting him here in A1 condition."
Williams said: "These big pots are hard to come back and keep having a crack at and the horse is no spring chicken, but although he had a fall last time, those things don't seem to affect Coole Cody.
"With a lot of horses you're always nervous after a fall, but when this horse falls on the floor he thinks it's a bit of fun! He's a very angry character who will go to war every day if he could.
"He's just one of those rare breed of horses that's very tough and very genuine and faces the music every time he comes to a big gig. It's hard to put into words how tough a horse he is."
He went on: "The track suits him and I went through the form of the race - and unless I was missing something, I couldn't see why our horse was 12/1 and the horse that won the Paddy Power was the price he was.
"He's won a Paddy Power and he's won this. If he never wins another race in his life, he's a 10-year-old who has done nothing but try and help us every time he goes to a racecourse.
"These big ones are sweet, especially with the history of these races. I was brought up watching them and remember all those brilliant horses winning them.
"To be in the same context as them means an awful lot."