Follow CBSMIAMI.COM: Facebook | Twitter

MIAMI (CBSMiami) – A Miami Gardens police officer who was shot as he filled out some paper work in his patrol car is lucky to be alive.

READ MORE: SpaceX To Launch On Halloween If It Tames Toilet Trouble

“The officer is doing okay, we’re very thankful he is alive,” said Miami-Dade Police Benevolent Association President John Rivera who stopped by the hospital to visit Officer David Starling.

“He is very lucky to be alive. He had a guardian angel looking over him,” said Rivera. Miami Gardens Police spokesman, Officer Bill Bamford, said Starling was in good spirits and said he had surgery starting at 2:45 p.m. at Aventura Hospital.

Rivera told CBS4’s Peter D’Oench that Starling was shot in a “total ambush.”

“He was just sitting there writing a report as most police officers do on a regular basis and the individual decided to shoot at the car several times and he struck him once,” said Rivera.

Starling, who was struck in the buttocks, managed to radio for help as he followed the driver who had shot him. That man, who fired on Starling as he was being pursued, was eventually taken into custody.

No police officer fired their weapons during the course of taking the man into custody.

Miami Gardens police Chief Antonio Brooklen said he’s proud of the way his officers handled the situation.

“Every police officer that takes this job knows the risk, we take the good and the bad. We are second guessed in every situation. But when you take this job you have an understanding, that knows that you may not come home at the end of the day and yet and still these officers with the City of Miami Gardens they come to work every day. They come to work focused. They come to work with a renewed attitude to provide a safe environment for our citizens.”

READ MORE: Mega Job Fair In Sunrise, Companies Looking To Fill 6,000 Positions

Starling has been with Miami Gardens since 2007. He had also worked for the Jacksonville Sheriff’s Office from 1989 to 1999.

Rivera and Brooklen said Friday morning’s shooting was upsetting.

“There is no justification for it, none whatsoever,” said Brooklen.

“There are people bad on the street who instead of being in prison are trying to hurt law enforcement officers and do anything they can to harm society,” said Rivera “We’re seeing a breakdown of civilization as we know it. Little by little it has changed. We have seen a breakdown of society. For the last two or three years we have seen the streets getting meaner and more violent.”

Starling’s father, Leroy, who is also retired Jacksonville officer, spoke with CBS4 News over the phone.

“Well I am devastated. I still am devastated. It’s not every day that you get information that your son has been shot while doing his job in the line of duty. It’s something you pray for every night,” said Leroy Starling. “It’s just one of those things, you know that every time he straps that gun there’s always a possibility.”

But what Leroy Starling can’t understand is what motived the alleged shooter, David Mejia.

“It’s just something that I just don’t understand what motivates a person like that. You know, what their mentality is and why they’re so angry.”

MORE NEWS: Supply Chain Issues: 'There Really Are Problems Everywhere,' Even For Small Companies

Starling’s wife Belinda and another family member were brought to Aventura Hospital. Rivera expects that Starling will be kept at the hospital overnight.

Peter D'Oench