# Keyset Seeker 操作的开销
__*LIMIT 子句*__
__*优化 LIMIT offset 操作*__

```8
tidb> SELECT id, name, mass 
    -> FROM planets WHERE category_id = 1 AND mass <= 83163 AND NOT (mass = 83163 and id >= 113) 
    -> ORDER BY mass DESC, id DESC LIMIT 10;
+-----+--------------------+-------+
| id  | name               | mass  |
+-----+--------------------+-------+
|  37 | .Dbaxc?y}o2U6oJQNO | 82861 |
...
| 191 | `GM{f$&YuH{-|uuU3) | 76997 |
+-----+--------------------+-------+
10 rows in set (0.01 sec)

tidb> explain SELECT id, name, mass 
    -> FROM planets WHERE category_id = 1 AND mass <= 83163 AND NOT (mass = 83163 and id >= 113) 
    -> ORDER BY mass DESC, id DESC LIMIT 10;
+---------------------------------+---------+-----------+-------------------------------------+
| id                              | estRows | task      | access object                       |
+---------------------------------+---------+-----------+-------------------------------------+
| Projection_7                    | 10.00   | root      |                                     |
| └─Limit_12                      | 10.00   | root      |                                     |
|   └─~!@IndexLookUp_43              | 10.00@!~   | root      |                                     |
|     ├─Selection_33(Build)       | 31.89   | cop[tikv] |                                     |
|     │ └─IndexRangeScan_31       | 31.95   | cop[tikv] | table:planets, index:mass(mass, id) |
|     └─Selection_34(Probe)       | 10.00   | cop[tikv] |                                     |
|       └─TableRowIDScan_32       | 31.89   | cop[tikv] | table:planets                       |
+---------------------------------+---------+-----------+-------------------------------------+
7 rows in set (0.00 sec)
```

------------------------------------------------------------

The execution plan IndexLookUp tells you the query have to access at least 10 rows, and there are no index full scan.
