Strange problem I can't seem to get my head around. I have a table in a MySQL database with the following structure...
CREATE TABLE IF NOT EXISTS `tblbaseprices` (
`base_id` bigint(11) NOT NULL auto_increment,
`base_size` int(10) NOT NULL default '0',
`base_label` varchar(250) default NULL,
`base_price_1a` float default NULL,
`base_price_2a` float default NULL,
`base_price_3a` float default NULL,
`base_price_1b` float default NULL,
`base_price_2b` float default NULL,
`base_price_3b` float default NULL,
`site_id` int(11) default NULL,
PRIMARY KEY (`base_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=134 ;
The last base_id I have in there is 132. I assume a couple of records have been deleted to auto_increment is set to 134, as you can see about. I am trying to run the following SQL statement, and when I do, I get the error "Duplicate entry '2147483647' for key 1".
INSERT INTO tblbaseprices (site_id, base_size, base_price_1a, base_price_2a, base_price_3a, base_price_4a) VALUES ('', '', '', '', '', '')
Does anybody have any ideas?
Many thanks!
2^31 − 1 = 2,147,483,647
The number 2,147,483,647 is ... the maximum value for a 32-bit signed integer in computing
2147483647 is the largest int value for mysql. Just change the type from int to bigint.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With