# 思路1

GROUP BY + COUNT + LIMIT

用了group by之后的count，count的是分组内的数据的个数。不管count是出现在group by前还是后。

```sql
SELECT customer_number
FROM orders 
GROUP BY customer_number
ORDER BY COUNT(*) DESC
LIMIT 1;
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://851958789.gitbook.io/notes/0586_customer_placing_the_largest_number_of_orders/slt.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
