It happened at around 4 a.m. outside the 11:11 Restaurant and Lounge at 10th Avenue and West 211th Street.
Officers were patrolling the area when they spotted a group in a disagreement.
Private security guards intervened, and the NYPD officers started to walk away, thinking the situation resolved.
Police say that's when a gunman, identified as 25 year old Isamuel Alcantara of the Bronx, opened fire. One officer returned fire, striking Alcantara in the hip.
WATCH: Raw video of shooting scene in Inwood
Alcantara was taken to Harlem Hospital, where police said he was undergoing surgery.
Two more gunshot victims were found at the scene, and two other victims walked to the nearby Allen Pavilion Hospital.
All four were being treated for injuries described as non-life-threatening.
The police officer was taken to the hospital to be checked out for tinnitus, or ringing in the ears.
Alcantara has an extensive criminal record. The gun police say he fired was recovered at the scene.
It appears to be an unregistered "ghost gun," one with no serial number that can be bought and built at home.
These have been a major, ongoing concern for law enforcement.
Police are still looking for other suspects in the shooting,
This is the second shooting in a week outside an Inwood nightclub.
Last Monday morning at almost the exact same time, a man was killed outside the Opus Lounge on West 202nd Street.
Police say the shootings are not related. But neighbors are fed up.
"The guns - it's a lot of guns in the street and everything," said Yudesca Kasse.
"For now, I just want everybody to check when they go into a club to see if they have anything on and take care of yourself because it's crazy," said Marlene Rodriguez.
Asked if she thinks bars should require patrons to pass through metal detectors, Rodriguez replied, "I think so, too. They're supposed to. This is very crazy lately."
ALSO READ | Exclusive: Asian man feared for life during road rage attack on Cross Bronx Expressway
* Get Eyewitness News Delivered
* More Manhattan news
* Send us a news tip
* Download the abc7NY app for breaking news alerts
* Follow us on YouTube
Submit a News Tip