Police said the officer, a border policeman, spotted a woman who appeared to be behaving suspiciously and tried to stop her. When he pursued her, she turned and stabbed him, and he shot her.
The attacker was taken to hospital, while initial indications were that the officer was not seriously wounded.
It was the second knife attack of the day and the 17th targeting Israelis or Jews since October 3, most committed by young Palestinians. Two Israelis have been killed in the wave of stabbings and around 20 wounded.