OAKLAND, Calif. – The Alameda County Sheriff’s Office has stripped 47 deputies – 10% of the force – of their guns and arrest powers because they failed psychological exams in the wake of a fatal double shooting allegedly committed by a former deputy.

It was “horrible’’ to have to relieve the deputies of their duties, sheriff’s spokesman Lt. Ray Kelly told KTVU-TV.

The station obtained a copy of a letter notifying the deputies of their change of status last Friday. The deputies will still receive their pay and benefits.

The move came after the Sheriff’s Office conducted an internal audit of deputies’ psychological examinations from January 2016 to the present.

The letter from Sheriff Gregory Ahern notified a deputy – whose name was blacked out in the copy – that the deputy had been graded “D. Not Suited” in a psychological evaluation and under state law couldn’t serve as a peace officer.

The letter said the Sheriff’s Office had previously been operating under incorrect advice received several years ago from the California Commission on Peace Officer Standards and Training, which said it could hire candidates who received such a rating.

Ahern said the deputy can be hired if a second examination declares him or her “suitable” and the office intends to schedule an appointment for such an exam.

“Our intention is to resolve this issue as quickly as possible,” Ahern wrote. “We also intend to have you return to full duty status once you obtain a ‘Suitable’ finding.”

Kelly said he hoped that the retests would occur in the next two months. The tests will be conducted by a psychologist who doesn’t work for the sheriff, he said.

Deli fraud:Father-son duo charged with fraud, market manipulation in $100 million NJ deli scheme