Added query with join.