如何以动态方式删除第一行或最后一组行 [英] How do I delete either the first or last set of rows in a dynamic fashion
本文介绍了如何以动态方式删除第一行或最后一组行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想删除某个表中的前100行或后100行(按主键排序).
I would like to delete the first 100 rows or the last 100 rows in a certain table (ordered by the primary key).
注意:大量数据正在后台处理到该表中.
Note: Lots of data is being spooled into this table.
推荐答案
DELETE FROM table ORDER BY the field DESC|ASC limit 100
这篇关于如何以动态方式删除第一行或最后一组行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文