Details
-
New Feature
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Won't Do
-
1.0.8
-
None
-
RHEL 6.6
Description
I want to delete rows using order by clause, but MariaDB says it is not currently supported.
My test cases are belows:
MariaDB [input_test]> delete from test_log where stime < '2017-03-19 00:00:00' limit 1000;
Query OK, 1000 rows affected (1.83 sec)
MariaDB [input_test]> delete from test_log where stime < '2017-03-19 00:00:00' order by stime limit 1000;
ERROR 1815 (HY000): Internal error: DML Statement with order by clause is not currently supported.
MariaDB [input_test]> delete from test_log order by stime asc limit 1000;
ERROR 1815 (HY000): Internal error: DML Statement with order by clause is not currently supported.
MariaDB [input_test]> delete from test_log where stime in (select * from test_log order by stime limit 1000);
ERROR 1235 (42000): This version of MariaDB doesn't yet support 'LIMIT & IN/ALL/ANY/SOME subquery'
Are you willing to support this kind of query later? Or is there other way to use delete query with order by clause?