Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Error Registering Accounts


AzBach

Recommended Posts

I am relatively new to osCommerce so this may have been answered elsewhere, but I did a search and couldn't find the answer to my exact problem.

 

Whenever a customer tries to register this error appears:

 

1062 - Duplicate entry '1' for key 1

insert into address_book (customers_id, address_book_id, entry_firstname, entry_lastname, entry_street_address, entry_postcode, entry_city, entry_country_id, entry_gender, entry_company, entry_suburb, entry_zone_id, entry_state) values ('5', '1', 'Bob', 'Marle', '208 Doster Drive', '32707', 'Casselberry', '223', 'm', '', '', '18', '')

[TEP STOP]

 

I believe I am on version 2 and when I checked out the databases, I noticed the primary key is set to customers_id & address_book_id. I am assuming this is the source of my error, but to me it looks like it should work.

 

Any ideas or suggestions would be appreciated. I didn't want to mess with the code too much until I asked.

 

Thanks

 

Grant

Link to comment
Share on other sites

I went ahead and removed the primary key from the address_book table, this seems to have fixed the problem. Hopefully this won't affect anything else in the store. If anyone has done this and has experienced problems, please let me know. Thanks.

 

Grant

Link to comment
Share on other sites

I am relatively new to osCommerce so this may have been answered elsewhere, but I did a search and couldn't find the answer to my exact problem.

 

Whenever a customer tries to register this error appears:

 

1062 - Duplicate entry '1' for key 1

insert into address_book (customers_id, address_book_id, entry_firstname, entry_lastname, entry_street_address, entry_postcode, entry_city, entry_country_id, entry_gender, entry_company, entry_suburb, entry_zone_id, entry_state) values ('5', '1', 'Bob', 'Marle', '208 Doster Drive', '32707', 'Casselberry', '223', 'm', '', '', '18', '')

[TEP STOP]

 

I believe I am on version 2 and when I checked out the databases, I noticed the primary key is set to customers_id & address_book_id. I am assuming this is the source of my error, but to me it looks like it should work.

 

Any ideas or suggestions would be appreciated. I didn't want to mess with the code too much until I asked.

 

Thanks

 

Grant

I have answered this many times in this forum, but you can find a bandaid fix Here

Best Regards

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...