This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

This topic contains 9 replies, has 2 voices.

Last updated by Bruno Kos 3 months, 1 week ago.

Assigned support staff: Bruno Kos.

Author Posts
June 20, 2019 at 1:27 pm #4060177

pierluigiL

hi, I have a single database file with multiple languages, can't I just use this for import? for now I am interested in using only Italian and English.
I ask this because I update frequently and this file is automatically generated by my management software.
Thanks for collaboration

June 21, 2019 at 12:50 pm #4067243

Bruno Kos
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hi,

Thank you for contacting WPML support!

hi, I have a single database file with multiple languages, can't I just use this for import?

Could you perhaps explain in more detail on what kind of import are you referring to?

I ask this because I update frequently and this file is automatically generated by my management software.

I am also not entirely clear on what are you referring to here - what kind of file is automatically generated files? I'm not sure if this will help, but have a look at the documentation, it is related to our WPML All Import plugin:
https://wpml.org/documentation/related-projects/wpml-all-import-plugin-website-import-with-wpml/

However, if you're looking for something more advanced and custom, possibly even setting up a cron to do the import job for you, maybe you should consider reaching out to our contractors:
https://wpml.org/contractors/

Regards,
Bruno Kos

June 21, 2019 at 1:13 pm #4067323

pierluigiL

Hi,
at this link you can see my dtb
hidden link
I would not like to divide the file but import all product translations for Italian, English for now from this single file (and in the future also French and German). It's possible? Thank you

June 21, 2019 at 1:42 pm #4067527

Bruno Kos
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hi,

I'm afraid that it is not possible:
https://wpml.org/documentation/related-projects/wpml-all-import-plugin-website-import-with-wpml/#how-to-import-posts

"""""""""""""""""""""""""""""""""""""""""""""""""""
You need to pay attention to a few minor things:
You need to import the first posts in the original language
Prepare your CSV/XML file with posts in the original language, as described above. Then start importing following the usual importing process.
...
"""""""""""""""""""""""""""""""""""""""""""""""""""

Regards,
Bruno Kos

July 2, 2019 at 6:20 am #4124209

pierluigiL

Hi Bruno,
I'm trying to import the english product after italian.
works for the first 140 products of 3753, then gives me this error.
Is it a server or file problem?
thank you
Fri, 28 Jun 2019 09:26:16 GMT [error] [client 83.211.79.2] - hidden link - AH01215: WordPress database error You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1 for query SELECT count(object_id) FROM wp_term_relationships WHERE object_id = 42303 AND term_taxonomy_id IN () made by do_action('admin_init'), WP_Hook->do_action, WP_Hook->apply_filters, PMXI_Plugin->adminInit, PMXI_Admin_Import->process, PMXI_Import_Record->process, wp_update_post, wp_insert_post, do_action('save_post'), WP_Hook->do_action, WP_Hook->apply_filters, WCML_Synchronize_Product_Data->synchronize_products, WCML_Synchronize_Variations_Data->sync_product_variations_custom_data, WCML_Products->is_variable_product: /web/htdocs/www.funware.it/home/wp-admin/admin.php, referer hidden link

July 2, 2019 at 7:19 am #4124551

Bruno Kos
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hi,

There could be several reasons why this occurs. Let's try this:

- set WP Memory limit to at least 256MB and try import then:
https://wordpress.org/support/article/editing-wp-config-php/#increasing-memory-allocated-to-php

How are you creating these files for imports? If you're using some custom software, I'm afraid I cannot help. However, have you tried using hidden link and try exporting/importing products, but without the WPML component first (so without WPML All Import plugin) - this may give us some idea on where the issue is.

If using plugins from hidden link and still seeing those issues, perhaps you want to reach out to their support and ask if they have something similar in databases?

Regards,
Bruno Kos

July 4, 2019 at 7:31 am #4140779

pierluigiL

Hi Bruno,
I took a big step forward by importing all the products in English. My site is in Italian, if you click on the home page on the flag in English, everything works perfectly, but if you click on a product and then on the translation, it doesn't work.
Can you help me out of courtesy?
Unique identifer that I used was SKU

July 4, 2019 at 7:56 am #4140905

Bruno Kos
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hi,

but if you click on a product and then on the translation, it doesn't work.

Can you tell me what is not working exactly? There are couple things we need to consider:
- are products in fact translated?
- are products set to fall back to original languages if no translation has been set?
-- https://wpml.org/documentation/translating-your-contents/displaying-untranslated-content-on-pages-in-secondary-languages/
- are translations connected properly?

For example:
hidden link
hidden link

Both links seem to be working for me, but I'm not sure if these are in fact the same products with a fallback function or is this a translation.

I am attaching few images so that you can see what am I referring to and how you can determine whether products have translations indeed and more importantly, if originals are connected with translations.

Regards,
Bruno Kos

July 5, 2019 at 11:59 am #4151069

pierluigiL

Hi Bruno,
Thank you for your answer.
my product are translated correctly, I used in the import operation the SKU as a connector, but they are not connected.
If I connect them manually as from your images, everything works.
hidden link

Isn't there a way to connect them now automatically?

second question: how does the menu not change language when I click on the flag?

thank you and have a good weekend

July 5, 2019 at 12:14 pm #4151233

Bruno Kos
Supporter

Languages: English (English )

Timezone: Europe/Zagreb (GMT+02:00)

Hi,

Isn't there a way to connect them now automatically?

The reason I'm afraid. WPML can't know which translation is translation of some other product. The only way to reconnect them is to try the import again by following all these steps:
https://wpml.org/documentation/related-projects/wpml-all-import-plugin-website-import-with-wpml/

One of the things clients tend to forget when importing translations is the following (they also sometimes choose the wrong language)

""""""""""""""""""""""""""""""""""""""""""""""""""""""""
Import posts in the second language
Now start the next import, but choose the file with the posts in the second language. Proceed as usual as you do when creating new items, but in the WPML Add-On metabox, you will have to set the correct language again. In addition, expand the section “Automatic Record Matching to Translate” and perform the following steps:

Select the file that you used to import the original posts. (When you perform multiple imports, the list of files to select will, of course be longer.)
Drag the field that you are using as the “connector” (see above) to the “Unique Identifier” field. This field “Unique Identifier” must be exactly the same to “Unique identifier” of the 1st (default) import.
That is it. Now proceed as usual, and this import will finish with posts in the second language that will be connected to the originals.
""""""""""""""""""""""""""""""""""""""""""""""""""""""""

You could also try adding connector manually and not using SKU. Perhaps trying these steps and performing an import anew would be faster than connecting all of these products.

As for this:
how does the menu not change language when I click on the flag?

Perhaps the pages and other menu items have not been translated, or the menu has not been synchronized?
https://wpml.org/documentation/getting-started-guide/translating-menus/

Regards,
Bruno Kos

The topic ‘[Closed] Import woocommerce from one file’ is closed to new replies.