I am trying to enter set of data in to my Cycles Table , The structure of the table as below.
When I am trying to insert the data into the table. I get error as below.
PHP Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '65535' for key 'PRIMARY''
My question is I am not trying to insert values into my primary key field which is id. then why I am getting duplication error. check my insertion query below.
I believe when auto increment field is left empty that should add values by itself.

When I made a manual check to see weather the record exit by
Select * from Cycles where id = 65535
var_dump($resutls) shows empty array and count($resutls) is zero


Thanks All
For your suggestion.
I found the error, I have to change in my table structure for id (smallint) to id (int(11)).
The smallint datatype was not doing any increments.