我的表有很多行,我想逐行删除,但是我知道正确的命令。
我知道删除单行代码:
DELETE FROM `ps_econt_order` WHERE `ps_econt_order`.`econt_order_id` = 108500;
我也在使用该代码:
DELETE FROM `ps_econt_order` WHERE `ps_econt_order` IN (500,501,504,503);
但是我只想用一个命令删除从505到108500的所有行。
答案 0 :(得分:2)
如果行是有序的,则可以在
之间使用DELETE FROM ps_econt_order
WHERE econt_order_id between 500 and 108500