写一个SQL查询,根据它们的重量对动物进行排名,其中1是最重的.
Assuming you have a table called "animals" with columns "name" and "weight", the following SQL query can rank the animals based on their weight:

```
SELECT name, weight, DENSE_RANK() OVER (ORDER BY weight DESC) AS rank
FROM animals
```

This query will return a result set with three columns: name, weight, and rank. The rank column will show the ranking of each animal based on its weight with 1 being the heaviest.