MySQL Forums
Forum List  »  InnoDB

AUTO INCREMENT ERROR
Posted by: Jean-Marie DUCHESNE
Date: April 07, 2016 05:02PM

Hello,

I work under linux and I have problem to insert data in a table.
When I create with the command line the table "test" with the code below, all is OK :
CREATE TABLE `test` (
`test_id` int(11) NOT NULL AUTO_INCREMENT,
`test1` int(11) DEFAULT NULL,
PRIMARY KEY (`test_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

After, I want to insert data with :
INSERT INTO test (test1) value (1);
and I have the error :
ERROR 1467 (HY000): Failed to read auto-increment value from storage engine

I have done :
ALTER TABLE test AUTO_INCREMENT = 1;
and I have the error :
ERROR 1025 (HY000): Error on rename of './MyNewDatabase/test' to './MyNewDatabase/#sql2-7e1a-5' (errno: -1)

Do you an idea to solve my problem?

Options: ReplyQuote


Subject
Views
Written By
Posted
AUTO INCREMENT ERROR
1862
April 07, 2016 05:02PM
690
April 07, 2016 08:40PM
775
April 08, 2016 01:19PM
661
April 08, 2016 03:45PM
726
April 08, 2016 06:45PM
762
April 09, 2016 12:38PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.