Skip Navigation

This thread is resolved. Here is a description of the problem and solution.

Problem:
The client is experiencing a database error indicating that the 'wp_icl_strings' table doesn't exist, despite the table being present in the database. Additionally, there are SQL syntax errors in the PHP log, and the site becomes very slow after activating the plugin.

Solution:
If you're experiencing a similar issue where a database error suggests a missing table but you've confirmed the table exists, you can safely ignore the message. Close the notification, refresh the page, and check if the message persists. Always ensure to back up your database before making any changes.

If the table is indeed missing, you can recreate it by following the instructions provided in our errata page: Missing _icl_strings and _icl_string_translations data tables.

Please note that the solution provided might be outdated or not applicable to your case. If the issue persists, we highly recommend checking related known issues at https://wpml.org/known-issues/, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If you still need assistance, please open a new support ticket in our forum: WPML support forum.

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.

Tagged: 

This topic contains 3 replies, has 2 voices.

Last updated by Andrey 1 year, 4 months ago.

Assisted by: Andrey.

Author Posts
February 6, 2024 at 9:46 am #15269938

francescoA-33

Hi, we have this issue in admin dashboard:

Table 'store.jhbwp_icl_strings' doesn't exist

Array
(
[language] => en
[context] => WP Endpoints
[gettext_context] =>
[domain_name_context_md5] => 3a448b300c73de9c6696651892b08d2f
[name] => wc-api
[value] => wc-api
[status] => 0
[translation_priority] => optional
[allow_empty_value] =>
)

but the table exists in the database, with 834 records.

and also, in the php log error we have:

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 ')
AND translations.source_language_code IS NOT NULL
AND ( posts.post_sta' at line 16 for query
SELECT jobs.rid, jobs.job_id as jobId, jobs.editor_job_id as ateJobId, jobs.automatic , translation_status.status,
translation_status.review_status, jobs.ate_sync_count > 100 as isLongstanding
FROM jhbwp_icl_translate_job as jobs
INNER JOIN jhbwp_icl_translation_status translation_status ON translation_status.rid = jobs.rid
INNER JOIN jhbwp_icl_translations translations ON translation_status.translation_id = translations.translation_id
INNER JOIN jhbwp_icl_translations parent_translations ON translations.trid = parent_translations.trid
AND parent_translations.source_language_code IS NULL
LEFT JOIN jhbwp_posts posts ON parent_translations.element_id = posts.ID
WHERE
jobs.job_id IN (
SELECT MAX(job_id) FROM jhbwp_icl_translate_job
GROUP BY rid
)
AND jobs.editor = 'ate'
AND ( translation_status.status IN (1,2,40) OR 1=0 )
AND translations.language_code IN ()
AND translations.source_language_code IS NOT NULL
AND ( posts.post_status IS NULL OR posts.post_status <> 'trash' )
made by require_once('wp-admin/admin.php'), require_once('wp-load.php'), require_once('wp-config.php'), require_once('wp-settings.php'), do_action('wp_loaded'), WP_Hook->do_action, WP_Hook->apply_filters, WPML\LIB\WP\Hooks::WPML\LIB\WP\{closure}, WPML\FP\Promise->resolve, WPML\FP\Right->chain, WPML\FP\Right->map, WPML\TM\ATE\Loader::getData, WPML\TM\ATE\Jobs::getJobsToSync, WPML\TM\ATE\Jobs::getJobsWithStatus
[06-Feb-2024 08:14:36 UTC] 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 ')
AND translations.source_language_code IS NOT NULL
AND ( posts.post_sta' at line 16 for query
SELECT jobs.rid, jobs.job_id as jobId, jobs.editor_job_id as ateJobId, jobs.automatic , translation_status.status,
translation_status.review_status, jobs.ate_sync_count > 100 as isLongstanding
FROM jhbwp_icl_translate_job as jobs
INNER JOIN jhbwp_icl_translation_status translation_status ON translation_status.rid = jobs.rid
INNER JOIN jhbwp_icl_translations translations ON translation_status.translation_id = translations.translation_id
INNER JOIN jhbwp_icl_translations parent_translations ON translations.trid = parent_translations.trid
AND parent_translations.source_language_code IS NULL
LEFT JOIN jhbwp_posts posts ON parent_translations.element_id = posts.ID
WHERE
jobs.job_id IN (
SELECT MAX(job_id) FROM jhbwp_icl_translate_job
GROUP BY rid
)
AND jobs.editor = 'ate'
AND ( translation_status.status IN (30) OR translation_status.review_status IN ( 'NEEDS_REVIEW','EDITING' ) )
AND translations.language_code IN ()
AND translations.source_language_code IS NOT NULL
AND ( posts.post_status IS NULL OR posts.post_status <> 'trash' )
made by require_once('wp-admin/admin.php'), require_once('wp-load.php'), require_once('wp-config.php'), require_once('wp-settings.php'), do_action('wp_loaded'), WP_Hook->do_action, WP_Hook->apply_filters, WPML\LIB\WP\Hooks::WPML\LIB\WP\{closure}, WPML\FP\Promise->resolve, WPML\FP\Right->chain, WPML\FP\Right->map, WPML\TM\ATE\Loader::getData, WPML\TM\ATE\Jobs::getJobsWithStatus

and the site, after the activation of the plugin it's very slow

February 6, 2024 at 10:16 am #15270477

Andrey
WPML Supporter since 06/2013

Languages: English (English ) Russian (Русский )

Timezone: Europe/Kyiv (GMT+03:00)

Thank you for contacting WPML support.

You can disregard this message if you have confirmed that the table exists in the database. Click close, refresh the page, and check if the message is gone.

However, before making any changes, we strongly recommend you back up your database.

If the table still does not appear, you can create it using the following link: https://wpml.org/errata/missing-_icl_strings-_icl_string_translations-data-tables/.

February 6, 2024 at 11:08 am #15270933
francescoA-33

Thank you for your reply, and about this error in the wp-debug:

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 ')
AND translations.source_language_code IS NOT NULL
AND ( posts.post_sta' at line 16 for query
SELECT jobs.rid, jobs.job_id as jobId, jobs.editor_job_id as ateJobId, jobs.automatic , translation_status.status,
translation_status.review_status, jobs.ate_sync_count > 100 as isLongstanding
FROM jhbwp_icl_translate_job as jobs
INNER JOIN jhbwp_icl_translation_status translation_status ON translation_status.rid = jobs.rid
INNER JOIN jhbwp_icl_translations translations ON translation_status.translation_id = translations.translation_id
INNER JOIN jhbwp_icl_translations parent_translations ON translations.trid = parent_translations.trid
AND parent_translations.source_language_code IS NULL
LEFT JOIN jhbwp_posts posts ON parent_translations.element_id = posts.ID
WHERE
jobs.job_id IN (
SELECT MAX(job_id) FROM jhbwp_icl_translate_job
GROUP BY rid
)
AND jobs.editor = 'ate'
AND ( translation_status.status IN (1,2,40) OR 1=0 )
AND translations.language_code IN ()
AND translations.source_language_code IS NOT NULL
AND ( posts.post_status IS NULL OR posts.post_status <> 'trash' )
made by require_once('wp-admin/admin.php'), require_once('wp-load.php'), require_once('wp-config.php'), require_once('wp-settings.php'), do_action('wp_loaded'), WP_Hook->do_action, WP_Hook->apply_filters, WPML\LIB\WP\Hooks::WPML\LIB\WP\{closure}, WPML\FP\Promise->resolve, WPML\FP\Right->chain, WPML\FP\Right->map, WPML\TM\ATE\Loader::getData, WPML\TM\ATE\Jobs::getJobsToSync, WPML\TM\ATE\Jobs::getJobsWithStatus
[06-Feb-2024 08:14:36 UTC] 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 ')
AND translations.source_language_code IS NOT NULL
AND ( posts.post_sta' at line 16 for query
SELECT jobs.rid, jobs.job_id as jobId, jobs.editor_job_id as ateJobId, jobs.automatic , translation_status.status,
translation_status.review_status, jobs.ate_sync_count > 100 as isLongstanding
FROM jhbwp_icl_translate_job as jobs
INNER JOIN jhbwp_icl_translation_status translation_status ON translation_status.rid = jobs.rid
INNER JOIN jhbwp_icl_translations translations ON translation_status.translation_id = translations.translation_id
INNER JOIN jhbwp_icl_translations parent_translations ON translations.trid = parent_translations.trid
AND parent_translations.source_language_code IS NULL
LEFT JOIN jhbwp_posts posts ON parent_translations.element_id = posts.ID
WHERE
jobs.job_id IN (
SELECT MAX(job_id) FROM jhbwp_icl_translate_job
GROUP BY rid
)
AND jobs.editor = 'ate'
AND ( translation_status.status IN (30) OR translation_status.review_status IN ( 'NEEDS_REVIEW','EDITING' ) )
AND translations.language_code IN ()
AND translations.source_language_code IS NOT NULL
AND ( posts.post_status IS NULL OR posts.post_status <> 'trash' )
made by require_once('wp-admin/admin.php'), require_once('wp-load.php'), require_once('wp-config.php'), require_once('wp-settings.php'), do_action('wp_loaded'), WP_Hook->do_action, WP_Hook->apply_filters, WPML\LIB\WP\Hooks::WPML\LIB\WP\{closure}, WPML\FP\Promise->resolve, WPML\FP\Right->chain, WPML\FP\Right->map, WPML\TM\ATE\Loader::getData, WPML\TM\ATE\Jobs::getJobsWithStatus

New threads created by Andrey and linked to this one are listed below:

https://wpml.org/forums/topic/split-wordpress-database-error-you-have-an-error-in-your-sql-syntax/

February 6, 2024 at 12:56 pm #15271892

Andrey
WPML Supporter since 06/2013

Languages: English (English ) Russian (Русский )

Timezone: Europe/Kyiv (GMT+03:00)

Ok, I see now that there is an extra error. I opened a new ticket for this issue. This will also help other users with similar problems find solutions when searching the forum.

I will assist you here: https://wpml.org/forums/topic/split-wordpress-database-error-you-have-an-error-in-your-sql-syntax/