Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

When an Ohio police officer retired this week after 34 years of service, he assumed his police dog partner would be joining him.

But thanks to a state law that both retired Marietta police officer Matthew Hickey and the town’s mayor disagree with, the animal will be auctioned off — leaving Hickey fuming, and donors chipping in thousands so Hickey can put in a bid.

"I love K-9 training and K-9 work,” Hickey told NBC News. Hickey became a K-9 police office in 1998 and has been with Ajax for four years.

"To me it’s like raising a child," Hickey said. "You get bonded just from the basic training. You watch his breathing, his tail movements.”

"You notice changes in him that could indicate someone hiding. Or if you’re doing narcotic work, you notice the change in the way he’s breathing when he picks up odors — he’s hunting," Hickey said. "We communicate in our behaviors.”

But Ajax was purchased by the city and still has several years left in his capacity to serve, even though the animal doesn’t currently have a qualified handler.

Ajax gets a pat from his handler, Marietta police Officer Matthew Hickey.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

To determine the dog’s value, the city hired an outside vendor who said Ajax was worth $3,500

"I thought if I provided the money, I could buy the dog from the city," Hickey said.

But according to Ohio State Law 721.15, if the estimated value of city property is $1,000 or more it must be sold in an auction to the highest bidder.

"When you disband the (K-9) unit, the officer or handler can purchase the dog for one dollar," Marietta Law Director Paul Bertram said.

"In this situation, the city of Marietta is not disbanding the unit," Bertram said. ”There is still another officer who has a dog, so that provision does not apply.”

Marietta Mayor Joe Matthews says his hands are tied.

Ajax, a K-9 with the Marietta Police Dept. in Ohio, sits with the grandson of Officer Matthew Hickey. Hickey family

"Officer Hickey came in when he retired and wanted to buy the dog right then, but we couldn’t do it. It’s impossible," Matthews told NBC News. "I would have loved to, but the state law won’t allow us."

Hickey disagrees. "I believe the law is being interpreted wrong. They are misreading the term ‘unit,'" he said. "Our unit is disbanded."

Hickey’s family is also distraught about the possibility of losing Ajax. "He’s like a brother. He is amazing. He’s the biggest teddy bear," Hickey’s daughter, Danielle Leal, told NBC News.

The city of around 14,000 on the West Virginia border posted on their city Facebook page that the voices and concerns of the community are being heard and looked into.

People in Marietta and across the country have stepped up to help Hickey stay with Ajax.

A GoFundMe page has been started to raise money for Hickey to enter a bid for Ajax. As of Saturday evening, over $17,000 had been raised, and the page was shared nearly 10,000 times.

No date has yet been set for Ajax’s auction. Potential buyers will submit sealed bids which will be opened on a certain date, and bidders will have a chance to increase their bids.

The mayor added a stipulation to the bidding.

"It has to be someone who is a dog handler and familiar with K-9 dogs," Matthews said. "I wish the state would change that law."