The San Diego County Sheriff's Department has released body camera video that shows the dramatic moments after a deputy was exposed to fentanyl during an arrest last month.

Fortunately, another officer was there with him.

It happened on July 3, as a patrol deputy was processing drugs at the scene of an arrest, ABC 13 reports.

In a documentary-style video released Wednesday by the sheriff's department showing the bodycam footage, Corporal Scott Crane explained it was his trainee who was exposed to fentanyl. He said it was their first radio call of the day.

"I was like 'hey dude, too can't get that close to it,'" Crane told Faiivae. "A couple seconds later he took some steps back and he collapsed."

The bodycam video showed Deputy Faiivae falling backwards onto the ground and how Crane used Narcan to help save him until he could be transported to the hospital.

"Fire department got there, put him on the gurney, his eyes rolled back in his head, and he started to OD again," Crane said. "He was OD'ing the whole way to the hospital."

It ends with Faiivae saying, "I'm Deputy David Faiivae and I almost died of a fentanyl overdose."