Web Hosting Forum | Lunarpages


*
Welcome, Guest. Please login or register.
Did you miss your activation email?



Login with username, password and session length
February 09, 2012, 04:22:49 PM

Pages: [1]   Go Down
  Print  
Author Topic: PHPMyAdmin duplicate key error  (Read 1674 times)
jonasgrumby
Newbie
*
Offline Offline

Posts: 5


« on: June 08, 2010, 02:35:51 PM »

Hi all,

I'm trying to import the install sql file from the MultiGeoZone / MultiTable Shipping module for OS Commerce. When I try to import the sql file in PHPMyAdmin I get this error message: #1062 - Duplicate entry '0' for key 1

Can anyone tell me what to change in the import file to avoid this? This is the file. I have already tried changing both zeroes to ones but got the same message. Thanks.

Code:
INSERT INTO configuration_group VALUES ('', 'MultiGeoZone MultiTable Shipping', 'The options which configure the MultiGeoZone MultiTable Shipping Module', '1', '1');

UPDATE configuration_group SET sort_order = last_insert_id() WHERE configuration_group_id = last_insert_id();

INSERT INTO configuration VALUES ('', 'Number of Geo Zones', 'MODULE_SHIPPING_MZMT_NUMBER_GEOZONES', '3', 'The number of shipping geo zones.', last_insert_id(), '0', NULL, now(), NULL, NULL),
                                 ('', 'Number of Tables per Geo Zone', 'MODULE_SHIPPING_MZMT_NUMBER_TABLES', '3', 'The number of shipping tables per geo zone.', last_insert_id(), '0', NULL, now(), NULL, NULL);
Logged
jonasgrumby
Newbie
*
Offline Offline

Posts: 5


« Reply #1 on: June 09, 2010, 01:20:56 PM »

Well of course it turned out to be something simple and stupid. All I had to was un-check "Do not use AUTO_INCREMENT for zero values" on the import screen.

Even though nobody was able to provide the answer, thanks for entertaining my thought process.
Logged
Pages: [1]   Go Up
  Print  
 
Jump to: