Tested on MYSQL Database
Solution 1:
SET FOREIGN_KEY_CHECKS = 0;
TRUNCATE table1;
Solution 2:
DELETE FROM table1;
ALTER TABLE table1 AUTO_INCREMENT = 1;
TRUNCATE table1;
This works for me. I hope, this will help you also. Thanks for asking this question.