Salta la navigazione

Questo thread è stato risolto. Ecco una descrizione del problema e della soluzione.

Problem:
You are encountering numerous errors in your Error Log that mention WPML, specifically a WordPress database error indicating that the user has exceeded the 'max_questions' resource limit.
Solution:
The issue is not caused by WPML but by your hosting provider limiting database queries. We recommend trying to set unlimited database queries using the following SQL commands:

SET @MAX_QUESTIONS=0; FLUSH;

or

UPDATE user SET max_questions = 0 WHERE user = 'yourusername'; FLUSH PRIVILEGES;

However, please consult with your hosting provider before making these changes to ensure that it is permissible.

If this solution does not apply to your situation, or if it seems outdated, 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 further assistance is needed, please open a new support ticket at WPML support forum.

Questo è il forum di assistenza tecnica di WPML, il plug-in multilingue di WordPress.

La sua lettura è permessa a tutti, ma la pubblicazione è riservata esclusivamente ai clienti di WPML. Il team di WPML risponde sul forum 6 giorni su 7, 22 ore su 24.

Etichettato: 

Questo ticket contiene 1 risposta, ha 0 voci.

Ultimo aggiornamento da Laura 1 settimana fa.

Assistito da: Laura.

Autore Messaggi
Gennaio 17, 2025 a 10:32 pm #16608400

raffaellaM

Contesto del problema:
I am trying to check my Error Log in the File Manager and I see many errors that mention WPML. I am not sure if the problem is related to WPML or WooCommerce. This is my website link nascosto. I am pasting a small part of the code here and will try to attach a txt with the complete errors:

[17-Jan-2025 01:17:48 UTC] WordPress database error User 'enk_WPXX' has exceeded the 'max_questions' resource (current value: 1) for query SELECT wpml_translations.translation_id, wpml_translations.element_id, wpml_translations.language_code, wpml_translations.source_language_code, wpml_translations.trid, wpml_translations.element_type FROM xCJ_icl_translations wpml_translations JOIN xCJ_term_taxonomy tax ON wpml_translations.element_id = tax.term_taxonomy_id AND wpml_translations.element_type = CONCAT('tax_', tax.taxonomy) JOIN xCJ_icl_translations tridt ON tridt.element_type = wpml_translations.element_type AND tridt.trid = wpml_translations.trid WHERE tridt.element_id IN(342) made by require('wp-blog-header.php'), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts, update_post_caches, update_object_term_cache, wp_get_object_terms, get_terms, WP_Term_Query->query, WP_Term_Query->get_terms, WP_Term_Query->populate_terms, get_term, apply_filters('get_term'), WP_Hook->apply_filters, SitePress->get_term_adjust_id, WPML_Term_Adjust_Id->filter, WPML_Element_Translation->element_id_in, WPML_Element_Translation->maybe_populate_cache

Sintomi:
I see many errors in the Error Log mentioning WPML, including WordPress database error User 'enk_WPXX' has exceeded the 'max_questions' resource (current value: 1) for query
SELECT
wpml_translations.translation_id,
wpml_translations.element_id,
wpml_translations.language_code,
wpml_translations.source_language_code,
wpml_translations.trid,
wpml_translations.element_type
FROM xCJ_icl_translations wpml_translations

JOIN xCJ_term_taxonomy tax
ON wpml_translations.element_id = tax.term_taxonomy_id
AND wpml_translations.element_type = CONCAT('tax_', tax.taxonomy)

JOIN xCJ_icl_translations tridt
ON tridt.element_type = wpml_translations.element_type
AND tridt.trid = wpml_translations.trid
WHERE tridt.element_id IN(342) made by require('wp-blog-header.php'), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts, update_post_caches, update_object_term_cache, wp_get_object_terms, get_terms, WP_Term_Query->query, WP_Term_Query->get_terms, WP_Term_Query->populate_terms, get_term, apply_filters('get_term'), WP_Hook->apply_filters, SitePress->get_term_adjust_id, WPML_Term_Adjust_Id->filter, WPML_Element_Translation->element_id_in, WPML_Element_Translation->maybe_populate_cache

Domande:
Is the problem related to WPML or WooCommerce or what?
How can I resolve if related to WPML?

Gennaio 20, 2025 a 10:22 am #16612452

Laura
Supporter

Lingue: Inglese (English ) Italiano (Italiano )

Fuso orario: Europe/Rome (GMT+01:00)

Salve,

grazie per averci contattato.

Il problema non è causato da WPML, ma dall'hosting che limita le chiamate al database.

Puoi provare ad impostare chiamate illimitate usando queste query nel database

SET @MAX_QUESTIONS=0 ; 
FLUSH ;

oppure

UPDATE user SET max_questions = 0 WHERE user = 'nomeutente' ;
FLUSH PRIVILEGES;

ma chiedi prima all'hosting se è possibile farlo.