Andarzbad (from Middle Persian: Andarz, "advice, counsel") was a Sasanian administrative office meaning "chief advisor", "chief councillor" or "chief of staff". The andarzbads were assigned to cities within the Sasanian Empire such as Ardashir-Khwarrah (i.e. Gor) or entire provinces, such as Sakastan. The main court andarzbad, known as the darandarzbad, served the Shahanshah ("King of Kings") directly and was one of the highest-ranking dignitaries within the Sasanian court. However, there were also andarzbads who served in other functions. There was the andarzbad ë aswÃÂragÃÂn, who instructed the Sasanian knights, or according to Anahit Perikhanian the andarzbadë wÃÂspuhragÃÂn, who exercised executive authority within the King's domain. The "andarzbad of the queens" (Middle Persian: bþnykn hndrcpt; Parthian: MLKTEn hndrzpty) dates back to the reign of Shapur I (240âÂÂ170) and is attested in his inscription at the Ka'ba-ye Zartosht. The mà ÂgÃÂn-andarzbad ("advisor of the magi") was a dignitary who effectively functioned as a legal consultant and held status as "one of the highest ranking dignitaries of the priestly class". M. L. Chaumont adds that the mà ÂgÃÂn-andarzbad office "was quite different from that of the mà ÂbadÃÂn mà Âbad". Andarzgar ("counselor", "teacher"), a less familiar Sasanian title, may have been modeled on andarzbad but this remains uncertain.