The officer was employed at a Duane Reade at West 94th Street and Broadway when he saw two men, ages 42 and 66, in a dispute near the entrance of the store.
He told the two men to take the dispute outside, and police say the 42-year-old man pulled out a gravity knife and stabbed the 66-year-old man in the chest.
The suspect then fled on foot, with the off-duty officer in pursuit.
When the suspect got the corner of West 94th Street and Amsterdam Avenue, he turned towards the officer while refusing to drop his knife.
The officer pulled his service weapon and fired at least five shots, hitting the man — who is apparently homeless — in the arm and the hip.
He was taken to St. Luke’s and is expected to survive.
His knife was recovered at the scene.
The man who was stabbed was also taken to the hospital, as was the officer.
What sparked the initial dispute is unclear, but there is speculation it may have had to do with shoplifting.