Mustafa II
In May 1706, he was appointed as Grand Vizier. According to the "Encyclopaedia of Islam", he was "the first competent Grand Vizier of the reign", and enjoyed high favour with the Sultan, who in 1708 married his niece Emine Sultan (a daughter of Mustafa II) to him. Thus Ali gained the title "damat" ("groom") to the Ottoman dynasty.