Answering top-k representative queries on graph databases