Shang Shang Shang clung on grimly to provide Wesley Ward with another Royal Ascot success in the Norfolk Stakes.
The ebullient American trainer had saddled nine previous winners at the showpiece fixture, including No Nay Never in this race five years ago.
Shang Shang Shang was the only filly in a 10-strong field for this five-furlong Group Two, but bounced out of the stalls and was soon leading her male counterparts in the hands of Joel Rosario.
One by one the 5-1 shot saw off her rivals, but she needed the line badly in the final 100 yards and Pocket Dynamo lunged late to almost join her passing the post.
The judge confirmed Shang Shang Shang had recorded a nose victory, with Land Force back in third.
The previously unbeaten 4-1 favourite Vintage Brut was bitterly disappointing.
Ward said: “To win this race with a filly is just unbelievable. I come here every year and we were scratching our heads the first two days and we were going back to the beginning wondering if we were in the right place.
“I thought she’d won but, like York (with Lady Aurelia in the Nunthorpe), you never know.
“There was a long wait until they announced it but it was great.
“We knew Shang Shang Shang was better on the firm ground than Chelsea Cloisters (who was beaten in Wednesday’s Queen Mary Stakes) and not as good on the soft ground. Chelsea Cloisters didn’t break good, this filly did, but I’m, excited right now.
“It’s win and you’re in so ultimately we want to go to the Breeders’ Cup. We’ll work back from that.”
Rosario said: “I thought for a second they were going to get me. She was responding to everything I asked of her. She was very calm and broke well, but I had to use her a little bit to get into her stride. It’s very different for her compared to America.
“It was very close in the last part but we got it done. I couldn’t tell if we’d got there, it was very close, thankfully she did.
“It means a lot to me, there are amazing people here and it is a dream come true being here. I’m really happy and blessed to be here.”
Robert Cowell, trainer of Pocket Dynamo, was delighted with his charge’s performance.
He said: “It was the shortest distance. I think he was in front a metre before the line and a metre after the line.
“I’d have preferred to have been beaten a length or a length and a half as I would have been far more satisfied. You can’t take it away from the horse, he has run an absolute cracker. He is tough and genuine and he will continue to have a good season.
“I will probably just keep him fresh now and go for something like the Molecomb.”
Aidan O’Brien is likely to switch back up in distance now with the third.
He said: “We are delighted with the run really. He would be very happy going back up to six as he won his maiden over six and he had a very good run over six last time.
“We went five today as we had to split them all up, but we are delighted with the run. I’d think something like the July Stakes we could go for next.”