Below is an context that describes a sql query, paired with an question that provides further information. Write an answer that appropriately completes the request.  # noqa: E501
### Context:
CREATE TABLE table_name_9 (rank INTEGER, total VARCHAR, gold VARCHAR)
### Question:
What was the average rank for the team that had more than 5 medals and more than 6 gold medals?
### Answer:
SELECT AVG(rank) FROM table_name_9 WHERE total > 5 AND gold > 6