United States Navy staff corps

In the United States Navy, commissioned officers are either line officers or staff corps officers. Staff corps officers are specialists in career fields that are professions unto themselves, such as physicians, lawyers, civil engineers, chaplains, and supply specialists. For example, a physician can advance to become the commanding officer (CO) of a hospital, the medical hospital on a hospital ship or large warship, or a medical school; or the Chief of the Medical Corps or of the Bureau of Medicine and Surgery. A supply officer can become the CO of a supply depot or a school, or the head of the Naval Supply Systems Command, etc.
The eight staff corps fall under different organizations throughout the Navy. The four medicine-related corps (Medical Corps, Dental Corps, Nurse Corps, and Medical Service Corps) all fall under the Bureau of Medicine and Surgery (BUMED). The Civil Engineer Corps and Supply Corps fall under two of the Navy's systems commands, respectively Naval Facilities Engineering Systems Command and Naval Supply Systems Command. The Judge Advocate General's Corps and Chaplain Corps are directly under the Navy Secretariat.
Staff Corps officers wear their specialty insignia on the sleeve of the dress blue uniforms and on their shoulder boards, in place of the star worn by line officers. On winter blue and khaki working uniforms, the specialty insignia is a collar device worn on the left collar, while the rank device is worn on the right.
History.
Current corps.
The office of Purveyor of Public Supplies, which would eventually evolve into the modern Supply Corps, was the first staff corps established, in 1795. The insignia of an oak leaf and acorn was adopted in 1830 to signify members of all staff corps then in existence, which included doctors and pursers. The Medical Corps originally additionally used a rod of Asclepius, while the Pay Corps (renamed the Supply Corps in 1919) used a cornucopia. 
The Medical Corps was formally founded in 1871, and after several design changes, in 1894 symbols resembling the modern insignia were adopted.
The Chaplain Corps was established and conferred relative rank in 1863. Chaplains had been appointed to the Navy since at least 1799. The staff corps insignia has evolved to include, as of 2019, four faith symbols: the Christian (Latin) cross, the Jewish Star of David and tablets, the Muslim crescent moon, and the Buddhist wheel of law.
The Civil Engineer Corps came into existence and was conferred relative rank in 1881, despite the fact that civil engineers had been employed by the Navy at least since 1827. The insignia of two crossed silver sprigs was adopted in 1905.
The Nurse Corps was established in 1908, and was granted relative rank in 1942. In 1948, female Naval officer uniforms were standardized using the current corps insignia. 
The Dental Corps was established in 1912, and its current insignia was adopted the following year. 
The Medical Service Corps was established in 1947; from 1941 until 1947, these officers had been part of the Hospital Corps, which previously had contained only warrant officers and enlisted men. Its current insignia was adopted the following year.
Although there had been a Judge Advocate General of the Navy since 1865, naval lawyers were line officers until they were split into their own staff corps, the Judge Advocate General's Corps, in 1967.
In 1918, the uniforms for all staff corps became identical to those of line officers, except for the distinguishing staff corps insignia. This was in response to complaints of inequality from staff corps officers. Prior to this, staff corps were distinguished by colored bands between the rank stripes, with a different color for each corps.
As of January 2015, the chiefs of five of the eight staff corps were women, including the Medical and Nurse Corps. The chiefs of the Civil Engineer, Chaplain, and Judge Advocate General's Corps were the first women to hold those posts.
Former corps.
The Engineer Corps was established in 1842, and they were conferred relative rank in 1859. From 1861 their insignia was four silver oak leaves in the form of a cross. The corps was disestablished in 1899 when its officers became line officers. The absorption of ship engineers into the line was the result of conflicts in the chain of command; as staff officers, engineers were not authorized to command ships, but when in battle the engineer was in charge of maneuvering the ship while under steam power, which occurred usually during battle. An exchange of open letters in 1878 voiced line officers' concerns that discipline was suffering because engineers were sometimes of higher rank than the ship's second-in-command executive officer. The assimilation of engineers as line officers was a compromise that clarified the chain of command and elevated the status of engineers. This move made the United States Navy unusual, as other modern navies such as the Royal Navy still have a separate engineering corps. Due to the increasing complexity of ships' engineering systems after World War II, commanding officers were themselves required to undergo basic engineering training.
The Corps of Professors of Mathematics was established in 1848, consisting of schoolmasters responsible for instructing midshipman at the Naval Academy, Naval Observatory, and aboard ships. Although they were civilians, discipline at the Naval Academy required that they be commissioned officers. Despite the name, their specialties were not limited to mathematics, but included astronomy, engineering, justice, and the teaching of foreign languages. They were conferred relative rank in 1863, and in 1866 their insignia was defined as a silver live oak leaf and an acorn. In 1916 it was provided that no further appointments would be made to the Corps of Professors of Mathematics, but that existing members would retain their appointment until all such members had died, resigned, or been dismissed. The corps' dissolution was the result of their own efforts in training line officers who would replace them, making civilian appointments as professors unnecessary.
The Naval Construction Corps was established and assigned relative rank in 1863, before which they were civilians. Their insignia was two silver leaves of live oak arranged vertically. In 1940, the corps was abolished and naval constructors became line officers.
List of current staff corps.
†An officer designator describes their general community or profession. The (fourth) digit (X) denotes whether the officer has a Regular (0), Reserve (5), or Full Time Support (7) commission.