An NYPD officer was stabbed in the Coney Island section of Brooklyn Thursday afternoon during a confrontation with a man carrying two knives, including one that was about 16 inches long.

It happened outside of a DMV, just feet from the 60th Precinct in Coney Island around 1 p.m., WABC reports.

Police say a responding officer went to investigate a dispute over parking and approached a man, who was armed with thick red gloves and two knives, one of which was about 16 inches long.

NYPD Commissioner Keechant Sewell said the officer was able to put distance between himself and the suspect until nearby officers came to help.

Police say the man continued to charge and that's when one of the officers fired four shots, striking the suspect in the leg and shoulder.

One of the officers, a 6-year veteran of the NYPD, was sliced in the hand while struggling with the suspect.