A guild was the association of craftsmen or sometimes merchants similar to a professional association but with elements of a secret society. Craftsmen joined a guild to protect their common interests and trade or craft secrets. The respective guild might, for example, hold exclusive rights to act in certain city or territory. These privileges extended sometimes to some occupations. Basically, the way to really learn a craft or trade was to join a guild as apprentice to eventually raise to the category of master.