Invalid or duplicate SKU

Pending

Import WP Addon - WooCommerce Updated 4 days ago 37 Replies

Michael asked 6 days ago on November 1, 2025 at 8:21 pm

Hi.

I have just bouht your import pro plugin and should be using it for woocommerce product import from csv, but it get a lot of “Invalid or duplicate SKU”.

I have sat item number as SKU and it is very unique.

See clips from error and setup here + see the CSV that I am using.

Language i file is Danish and “Varenummer” is SKU, and unique.

Also see clip from stock.

 

J

James replied Support Agent

6 days ago on November 1, 2025 at 8:25 pm

Hi Michael

Can you please export and attach your importer settings to this ticket by going to Tools > Import WP > Settings / Tools > Import / Export and select and export your importer as a JSON file.

James

MR

Michael replied

6 days ago on November 1, 2025 at 11:02 pm

Hi James.

Thank you for your quick answer.

Really nice, I would like very much to have this work. Here are the file.

Thank you!

Regards Michael

J

James replied Support Agent

6 days ago on November 1, 2025 at 11:20 pm

Hi Michael,

The issue is with your permission setup, you need to change the unique identifier to "Select a template field to be used as the unique identifier for each record." and then choose Product SKU, OR GTIN  from the dropdown (best to use the SKU as this has to be unique per product), as this will search for existing products using the chosen field.

As you currently have it set to "Select data from your import file to be used as the unique identifier per record.", with this set to {5}, which is cause the current "Invalid or duplicate SKU" due to it only referncing the file and not existing products.

James

 

MR

Michael replied

5 days ago on November 2, 2025 at 4:31 pm

Hi James.

Thank you! I changed what you wrote, but still not working.

I like the interface and the thinking in the program very much, but I can not become a friend with it, yet.

I end up having a lot of duplicate SKU, but it is not true. I checked.

I found out that the fault is that your program finds the translated items (Spanish and English), but it should only work on the primary Danish (and call WPML to translate per post).

This is the first error, these 3 ID’s have same SKU:

13253
32758
23555

It is wrong in normal terms in Woo, as the user only see the primary languages data, but if you shift to Spanish and English language, this is the explanation. Look at the attachments.

I found the option to disable plugins during import, so WPML could be diabled, but that does not seem like a solution, as WPML is needed for translating the import/update.

I have your plugin + WPML and Woo add on, see it in the clips alonside clip of WPML plugins. I think I got your WPML add on plugin before I installed the bougt Pro plugin from you. I hope the function of WPML add on still works, despite the sequence.

What to do, to have your import program not run into translated items when importing/updating?

Regards Michael

J

James replied Support Agent

5 days ago on November 2, 2025 at 6:41 pm

Hi Michael,

Sorry i had no idea you were using WPML, let me test this out and get back to you.

James

MR

Michael replied

5 days ago on November 2, 2025 at 7:04 pm

Thank you James.

Yes, I have 3 languages and are using WPML.

Your program knows that I have WPML, it suggested to install the WPML add on plugin.

I have been trying different things, but the same result, your program sees the ekstra translated WPML items and thinks that there are duplicate EAN because of this.

Thank you for your quick response and that you are testing.

Would you like to have a login for my site, so you can test it with the real data and a running installation with your program and WPML? It OK with me, I think you know what you are doing 😊

Regards Michael

MR

Michael replied

4 days ago on November 3, 2025 at 3:08 pm

Hi James.

Do you have news for me?

I am waiting to import 600 items via your plugin and would like to move on.

Would you like to have a admin login to our shop to work with the real data? Everything is there, WP, Woo, items, a running shop, your plugin, WPML plugin. Just be carefull there, it is live.

Looking forward to your response.

Regards Michael

J

James replied Support Agent

4 days ago on November 3, 2025 at 3:30 pm

Hi Michael,

I do have a solution, but i have not 100% tested across all integrations and plugins (once fully tested this version will be available).

This should fix your issue, but before running it i would recommend backing up your files and database so that you can restore if required.

Attached is a newer version of the plugin, please install and also change the unique identifier to the previous suggestion of "Select a template field to be used as the unique identifier for each record." and then choose Product SKU, OR GTIN  from the dropdown

James

MR

Michael replied

4 days ago on November 3, 2025 at 7:08 pm

Hi James.

Thank you, I will test it now.

Regards Michael

MR

Michael replied

4 days ago on November 3, 2025 at 7:45 pm

Hi James.

The new code is in and I did an import.

It had many errors. See clip and see my import file, it is fine I think and unique on the EAN (Varenummer).

Looking forward to have this working.

Do you want a login to our shop?

Regards Michael

 

J

James replied Support Agent

4 days ago on November 3, 2025 at 8:12 pm

For that importer can you please export and attach your current importer settings that you used to generate the latest import to this ticket by going to Tools > Import WP > Settings / Tools > Import / Export and select and export your importer as a JSON file.

 

MR

Michael replied

4 days ago on November 3, 2025 at 8:48 pm

Hi James.

OK, it is included here + the full error log in Excel.

I hope that you see the error and a good solution 👍😊

Also welcome to have a login to my site and see my Woo items and how WPML stores data and so on.

Regards Michael

J

James replied Support Agent

4 days ago on November 3, 2025 at 9:13 pm

Does your website have existing products that match the sku of the first item in the csv file? and if so which language is it in?

e.g. if you go to products, select all languages, and search for the sku what does it return.

MR

Michael replied

4 days ago on November 3, 2025 at 10:39 pm

Hi James.

The first item in the CSV is EAN 4027002001015 (Varenummer = EAN).

It exists in all 3 languages, see clips, and it is just like it shuld be, existing and in sync. This is an existing item that the import program should see as existing and therefore update, and not insert.

This item is old, from the 20/11-2024, so yes, very existing, ready for an update.

In the import setup I choose both insert and update, it is what I need to do with the import = insert new, not existing, items and update existing items with content of all fields in the CSV.

Regards Michael

 

 

J

James replied Support Agent

4 days ago on November 3, 2025 at 10:40 pm

I have been going round in circles, i have fixed some bugs relating to the idea of having the same sku/gtin across a product and its translations.

By mistake i stumbled upon this article: https://wpml.org/errata/invalid-or-duplicated-gtin-upc-ean-or-isbn/ which suggests there is an issue with wpml woocommerce and your current setup (using the supplied code fixed the error for me).

Please install and activate the latest attached version of importwp-wpml.

As an example using your latest importer config and csv file, i was able to import the first line in the default language, then import it again in another as a translation of the default language, and again in another language (all with the same sku and gtin).

Hope this helps

James

MR

Michael replied

4 days ago on November 3, 2025 at 11:01 pm

Ok.

Status on my installation is that the upgrade you sent here was installed right away as I answered, so it is on now and active.

The errors that I got, including line 1 with an existing item, was with your update installed.

And my WPML plugins and all other plugins are at latest updates.

Therefore I have nothing else to put on.

Or is your attachment here a newer update than the one from yesterday? The version number is the same.

And to your last part of your text. You dont mean that I must import my stock files per language? As now is 3 languages at my shop, meaning 3 runs, and if I later have 6 languages, 6 runs? Times different brands times once a month = a lot of runs and not smart and right ude of software. You may not mean it like this I guess. Please explain in other words what you mean in your last part of the text.

You are also very welcome to call me at +45 23216260.

Regards!

 

J

James replied Support Agent

4 days ago on November 4, 2025 at 7:52 am

The attached plugin from the latest ticket is the most recent development version of v0.0.3, please use that, it has the same version number because it is not yet publicaly available.

I only suggested running a seperate import per file based on your current settings bacause you have not configured the wpml panel of the importer to connect the translations based on the language.

A simplified guide on how to do that can be found here: https://www.importwp.com/docs/import-wpml-translations-from-csv-xml/ where you set the language of the translation and what it is a translation of.

James

MR

Michael replied

4 days ago on November 4, 2025 at 7:54 am

I checked, and as you see in the clip I had your upgrade installed, I did it when you sent it the first time.

I am looking forward to your reply to my message before this.

MR

Michael replied

4 days ago on November 4, 2025 at 7:58 am

Ok, I have overwritten the upgrade with the upgrade in the latest file now.

And I have read your guide to WPML.

Testing again.

MR

Michael replied

4 days ago on November 4, 2025 at 8:05 am

I stranded, what to select here? - See pics.

I guessed that I should pair item no. to item no., or EAN to EAN, but it does not seem to be the case.

My CSV import files does not have a language filed, they come from supliers in their native language and I got a lot of them.

I could add a language field to every post in the CSV's but what to write in it?

MR

Michael replied

4 days ago on November 4, 2025 at 8:07 am

... or else I can hide the last WPML option and only have WPML language open. That looks right and logical.

There I can select to what language I am importing, and your program or WPML will automaticily sync to all other languages.

See pic.

I will test like this now.

J

James replied Support Agent

4 days ago on November 4, 2025 at 8:10 am

I will add the sku and ean to that dropdown.

When you say each row comes from the suppliers in their native language, does that mean all products in the csv file are of the same language? (if that was the case you could just select the language from the dropdown and it would be the same for the whole file)

 

J

James replied Support Agent

4 days ago on November 4, 2025 at 8:16 am

Importing without the translation field will only mean the imported product will not be imported as a translation of another product.

MR

Michael replied

4 days ago on November 4, 2025 at 8:39 am

I got 175 errors, see pic.

At the same time you sent out a new WPML uprgade for your plugin, my Plugin menu had it. This was not installed with this import, it was with the upgrade from our dialouge here. As you see my run with that did not work.

Now I will install the official upgrade from you and run again with WPML option, language = Danish.

MR

Michael replied

4 days ago on November 4, 2025 at 8:45 am

Looking over the items now, it looks like insert new items is working fine, it is the update of existing items that fails.

I have installed youe official addon upgrade and are deliting the addede items from last run to have a realistic setup to test if your plugin now works here.

Importing again in a few minutes.

J

James replied Support Agent

4 days ago on November 4, 2025 at 9:02 am

This is still the same issue, did you look at this wpml issue: https://wpml.org/errata/invalid-or-duplicated-gtin-upc-ean-or-isbn/ that can cause the errors?

i would recommend when running the import, limiting the max number of rows so that you dont have to waste time for the importer to complete.

J

James replied Support Agent

4 days ago on November 4, 2025 at 9:28 am

I have just tested what you have suggested of not enabling the translation field and only the language, doing this does not allow you to import duplicate sku/gtin values, this is only possible if you set a translation, as without these settings you get the error "Ugyldigt eller duplikeret SKU (varenummer)."

Please installed the latest attached version that now has the gtin and sku fields available for selection on the wpml translation settings (screenshot attached showing settings)

 

MR

Michael replied

4 days ago on November 4, 2025 at 9:58 am

Hi.

I did the WPML work a round and ruined my WP, it stopped and I had to repair via my hosting. Only until I removed the work around and ran a repair and full update of all plugins, my installation was up again.

I reported it to WPML. See clip.

MR

Michael replied

4 days ago on November 4, 2025 at 10:10 am

And now I ran a new test with your setting from your picture and with the upgrade on.

Same errors. See clips and json.

Please guide me to have this working. I need to move on and have my shop working, and importing items, I must add a lot of other items, and to them pictures and text.

Thanks!

J

James replied Support Agent

4 days ago on November 4, 2025 at 10:24 am

You need that fix in place from wpml to get over the first rows error.

However this is only an issue because you are using the "GTIN, UPC, EAN, or ISBN" field, if you do not use this field you should be able to import.

1. Delete the imported products, and empty the products from the trash.
2. On the importer template, under the inventory panel clear the value in the "GTIN, UPC, EAN, or ISBN" field.
3. Change the translation field type from "GTIN, UPC, EAN, or ISBN" to "Product SKU".
4. On the RUn import tab, set the number of rows to 1, as this is a good amount to test.

MR

Michael replied

4 days ago on November 4, 2025 at 10:52 am

Yes, I found out the same, if I deleted import/update of GTIN then no errors.

But then the 2 secondary languages does not sync, only the primary danish language is inserted/updated. And this looks fine. Just need the 2 other to be synced also.

I am running a full import now and when this is done I will do it again with your new recomandation: 3. Change the translation field type from "GTIN, UPC, EAN, or ISBN" to "Product SKU".

If that works and gets the 2 sec. lang. updated as well, then I only need to write a small sript that sets GTIN = EAN for all items in all languages. That is easy and ok.

Lets hope that your no. 3. will include sec. langs. I hope.

MR

Michael replied

4 days ago on November 4, 2025 at 10:52 am

Yes, I found out the same, if I deleted import/update of GTIN then no errors.

But then the 2 secondary languages does not sync, only the primary danish language is inserted/updated. And this looks fine. Just need the 2 other to be synced also.

I am running a full import now and when this is done I will do it again with your new recomandation: 3. Change the translation field type from "GTIN, UPC, EAN, or ISBN" to "Product SKU".

If that works and gets the 2 sec. lang. updated as well, then I only need to write a small sript that sets GTIN = EAN for all items in all languages. That is easy and ok.

Lets hope that your no. 3. will include sec. langs. I hope.

J

James replied Support Agent

4 days ago on November 4, 2025 at 10:55 am

When you mention 2 secondary languages, what do you mean?

As you previously said your csv file does not say what language is on it?

MR

Michael replied

4 days ago on November 4, 2025 at 11:46 am

Hi.

I mean 2 secondary languages in the shop, in Woo. Our shop has danish as primary and spanish and english as secondary languages.

Not in the files. They are only in one format, one language and often in english.

The import is still running. An hour for 120 items, but still in progress.

J

James replied Support Agent

4 days ago on November 4, 2025 at 11:50 am

Is this importing images and other media, or just the same import?

I personally would have confirmed that it was all working before running the full import.

Is this still unresolved (I dont understand how this would be resolved if the importer knows nothing about the language, apart from the single language you have selected on the importer template):

But then the 2 secondary languages does not sync, only the primary danish language is inserted/updated. And this looks fine. Just need the 2 other to be synced also.

MR

Michael replied

4 days ago on November 4, 2025 at 12:41 pm

Yes, it is the same import as you have a copy of. Only text items, no media.

The import is still running. See pic.

Perhaps something is not efficient with WPML included.

The WPML wheel is turning around and working. See pic.

Comming back when import is done.

J

James replied Support Agent

4 days ago on November 4, 2025 at 12:51 pm

Never used the auto translate feature before, so i would recommend disabling during the import as you wouldnt want to waste credits (im guessing it costs to use credits) on imports that might not be correct.

To give you a comparison, running this locally takes only a couple of minutes.