1. A method comprising, by one or more computing devices: accessing a social graph comprising a plurality of nodes and a plurality of edges connecting the nodes, each of the edges between two of the nodes representing a single degree of separation between them, the nodes comprising: a first-user node corresponding to a first user associated with an online social network; and one or more second-user nodes that each correspond to a second user associated with the online social network, each of the second-user nodes being within a threshold degree of separation from the first-user node; receiving from the first user a text query comprising one or more character strings; identifying one or more of the second-user nodes, each of the identified second-user node corresponding to one or more of the character strings; identifying one or more of the edges, each of the identified edges being connected to one of the second-user nodes, and each of the identified edges corresponding to one or more of the character strings; and generating one or more recommended queries that each comprise references to one or more of the identified second-user nodes and one or more of the identified edges.