The man chosen to lead Lawrenceville’s police department after a sexual harassment scandal led to the police chief’s resignation admitted Thursday to having his own history of sexual indiscretions on the job.

With his wife standing behind him, Maj. Myron Walker told reporters at police headquarters that seven years ago, he devastated her by having an extramarital affair. According to internal affairs and disciplinary records obtained by The Atlanta Journal-Constitution, Walker had a relationship with a subordinate when he worked for the Gwinnett County Sheriff’s Office.

The affair went on for years until late 2014, when Walker and the woman got into a scuffle at her home and police were summoned, records show. An internal investigation found they had sex in a sheriff’s vehicle and in county administrative offices.

The sheriff’s office had demoted Walker from sergeant to corporal in 2015. He joined the Lawrenceville Police Department three years later as its second in command.

“My humiliation paled in comparison to the pain I’ve caused my wife, this same wife who stands with me today,” he said.

For several days this week, Walker and other city officials had urged the AJC to not report this information. Walker called Thursday’s press conference as the AJC was preparing to publish a story on Lawrenceville’s sexual harassment problems that included the acting chief’s disciplinary history in Gwinnett. That story is available at AJC.com and will publish in Sunday’s print editions.

The major is leading a police department that just experienced a shakeup in its top ranks after an internal investigation found that Chief Tim Wallis and the former head of criminal investigations, Capt. Ryan Morgan, had sexually harassed a female captain. The report revealed a culture of sexism that dated back years.