Assemblyman David I. Weprin, the Democratic candidate to replace former Representative Anthony D. Weiner in a special election on Sept. 13, is a Modern Orthodox Jew who keeps kosher, observes the Sabbath and has been to Israel at least eight times. So it comes as a surprise that, at this early stage of the short campaign, New York’s Ninth Congressional District finds itself talking about an unlikely subject — whether Mr. Weprin, who is unabashedly pro-Israel, is the best pro-Israel advocate.

Just as a May special election in a conservative district of western New York turned into an unexpected referendum on the Republican Party’s proposals about Medicare, the coming special election in a heavily Jewish district of Brooklyn and Queens is, at least for that district, emerging as a potential referendum on President Obama’s proposals about the Middle East.

“It will be a one-upsmanship on who is more pro-Israel,” said Chris Malone, an associate professor of political science at Pace University.

On Monday, former Mayor Edward I. Koch, a Democrat, endorsed the Republican candidate in the race, Bob Turner, a retired cable television executive, at a press conference at which he stood next to an Israeli flag. Mr. Koch has acknowledged that Mr. Weprin is a strong supporter of Israel, but argued that the election of Mr. Turner would serve as a rebuke to Mr. Obama for saying that Israel’s pre-1967 border should be the basis for a peace agreement.