ANKARA, Turkey (AP) _ Turkey's parliament failed to elect a reformist president in the first round of voting Thursday in humiliations for Prime Miinister Bulent Ecevit and the European Union.

Ecevit believed he had gained the promises of every party leader in the legislature to support Ahmet Necdet Sezer, chief of the constitutional court who has advocated democratic reforms.

``I don't even consider the probability that Sezer won't be elected,'' Ecevit said late Wednesday.

But parliament, which elects the chief of state, gave Sezer only 281 votes, instead of the 367, or two-thirds, of the 550 members, needed for a first-round win. Nine other candidates split the remaining votes, with the second highest vote getter, Nevzat Yalcintas, netting just 61. The vote was by secret ballot.

After Ecevit failed two weeks ago to get parliament to amend the constitution to give President Suleyman Demirel another term, he settled on Sezer as the ideal compromise candidate.

As head of Turkey's top court and a supporter of constitutional reforms, Sezer appealed to the European Union that has pressed for changes so Turkey can join the group.

Sezer also had also questioned the military's purge of officers suspected of links with Islamic groups, which pleaed the Islamic Virtue Party, which faces banning for challenging Turkey's secular system.

Sezer's views alarmed the military, which fears views political Islam as a major threat to Turkey's secular state. The top generals stayed away from a reception Sezer held this week.

But the opposition of the military to Sezer appeals to the European Union, which believes that Turkey's generals have had too much say in poliitics. The army has seized power three times since 1960.

Despite the first-round defeat for Sezer, Ecevit believes his candidate will win in the next round or the one after that when several candidates drop out.

``It is clear as of now that the results will be good for Mr. Sezer,'' Ecevit said. ``I am very optimistic about the results.''

The presidency in Turkey is a largely ceremonial post, but presidents are often powerbrokers in times of crises and can exert strong moral influence.