Jump to content
ding

[HELP] Duplicate entry '0-1' for key 1 ??

Recommended Posts

i import CSV to upload my products but PS warns me :
Duplicate entry '0-1' for key 1
"test" (ID 2) cannot be saved
anyone have the same problem?

  • Sad 1

Share this post


Link to post
Share on other sites

This error means that there is already a record with the same ID which needs to be unique.

You are either trying to import to a table that already has data, or you are trying to import identical records from your csv file

  • Like 1

Share this post


Link to post
Share on other sites

really thx, tomerg3.
i have already cleared data before i import csv file. and i reset "id_product" field to make it start 1;

Share this post


Link to post
Share on other sites
Guest

Let the database fix it by itself.
Login in phpadmin select "all" the tables at the bottom of the database's first page, choose "repair"in the dropdown menu,then the problem is fixed.

Share this post


Link to post
Share on other sites

I'm having the same problem. I used both methodes 1. the backup database function in PS and 2. Export via phpmyadmin. Next I tried to import this file via phpmyadmin in an other database (local test database) and I'm getting messages like this:

#1062 - Duplicate entry '3-klettverschluß' for key 'id_lang'

The table that causes this problems is always the Search_Word table

I have checked everything and I'm sure that this entry is not an duplicate. What is going wrong?

It should be a simple Export --> Import procedure, but I'm not getting it done!

Is there anyone who can help me out? It's driving me crazy after hours and hours of searching and trying.

Share this post


Link to post
Share on other sites

Hi, I was having the same problem with ps_search_index table because I am generating the search index from an external application. I have finally solved creating the table this way:

 

 

CREATE TABLE ps_search_word (

`id_word` int( 10 ) unsigned NOT NULL AUTO_INCREMENT ,

`id_lang` int( 10 ) unsigned NOT NULL DEFAULT '3',

`word` varchar( 100 ) NOT NULL ,

PRIMARY KEY ( `id_word` )

) ENGINE = MYISAM DEFAULT CHARSET = utf8;

 

 

I'm having the same problem. I used both methodes 1. the backup database function in PS and 2. Export via phpmyadmin. Next I tried to import this file via phpmyadmin in an other database (local test database) and I'm getting messages like this:

 

#1062 - Duplicate entry '3-klettverschluß' for key 'id_lang'

 

The table that causes this problems is always the Search_Word table

 

I have checked everything and I'm sure that this entry is not an duplicate. What is going wrong?

 

It should be a simple Export --> Import procedure, but I'm not getting it done!

 

Is there anyone who can help me out? It's driving me crazy after hours and hours of searching and trying.

  • Like 1

Share this post


Link to post
Share on other sites

The answer was in n° 4.

 

"Let the database fix it by itself.

Login in phpadmin select "all" the tables at the bottom of the database's first page, choose "repair"in the dropdown menu,then the problem is fixed. "

 

Can you believe it ? I've spent a full bloody day for this. How came that noone else has porposed this? I start to have the feeling that truly  knowledgable people rarely takes part in forum discussions. They keep thier knowledge tight and makes a living as consultants.

 

All the best

 

Hans

Edited by Bjarstal (see edit history)

Share this post


Link to post
Share on other sites

×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More