Skip to content Skip to sidebar

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.

Sun Mon Tue Wed Thu Fri Sat
- 8:00 – 13:00 9:00 – 13:00 9:00 – 13:00 8:00 – 12:00 8:00 – 12:00 -
- 14:00 – 17:00 14:00 – 18:00 14:00 – 18:00 13:00 – 17:00 13:00 – 17:00 -

Supporter timezone: Europe/Zagreb (GMT+01:00)

Tagged: 

This topic contains 3 replies, has 0 voices.

Last updated by Bruno Kos 6 days, 19 hours ago.

Assisted by: Bruno Kos.

Author Posts
January 8, 2026 at 1:44 pm #17713087

janneS-5

Both WPML and WooCommerce plugins are up to date. How to fix this?

Query Caller Component Error Message Error Code
SELECT COUNT(*)
FROM wp_comments
LEFT JOIN wp_posts AS wp_posts_to_exclude_reviews
ON comment_post_ID = wp_posts_to_exclude_reviews.IDLEFT
WHERE ( comment_approved = '1' )
AND comment_type NOT IN ('note')
AND comment_type != 'order_note'
AND comment_type != 'webhook_delivery'
AND comment_type != 'action_log'
AND wp_posts_to_exclude_reviews.post_type NOT IN ('product')
AND icltr2.language_code = 'fi'
AND (icltr_comment.language_code IS NULL
OR icltr_comment.language_code = icltr2.language_code )
WP_Comment_Query->get_comment_ids()
Plugin: woocommerce Unknown column 'icltr2.language_code' in 'where clause' 1054

January 8, 2026 at 2:23 pm #17713275

Bruno Kos
WPML Supporter since 12/2018

Languages: English (English ) German (Deutsch ) French (Français )

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

Hi,

Can you run this query in your database:

SELECT TABLE_SCHEMA, TABLE_NAME, COLUMN_NAME
FROM INFORMATION_SCHEMA.COLUMNS
WHERE COLUMN_NAME = 'language_code';

What does it return?

language_code should exist in both wp_icl_languages_translations and wp_icl_translations.

tables.jpg
January 16, 2026 at 12:19 pm #17736860

janneS-5

+---------------+-------------------------------+---------------+
| TABLE_SCHEMA | TABLE_NAME | COLUMN_NAME |
+---------------+-------------------------------+---------------+
| hunajafi | wp_icl_languages_translations | language_code |
| hunajafi | wp_icl_translations | language_code |
| hunajafi_test | wp_icl_languages_translations | language_code |
| hunajafi_test | wp_icl_translations | language_code |
+---------------+-------------------------------+---------------+

January 16, 2026 at 1:18 pm #17737092

Bruno Kos
WPML Supporter since 12/2018

Languages: English (English ) German (Deutsch ) French (Français )

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

The issue is not related to missing database columns then. The language_code column exists correctly in all required WPML tables.

The error possibly occurs because a query generated during WooCommerce comment retrieval references icltr2.language_code, but the corresponding WPML table alias is not JOINed in the query.

Would you be willing to provide me with WordPress and FTP credentials so I could investigate the issue directly?

And let me know where exactly does it show, what do I need to click/which URL to visit?

https://wpml.org/purchase/support-policy/privacy-and-security-when-providing-debug-information-for-support/

I marked your next reply as private so that you can safely add credentials.