Database Warning
-
Hey Guys! Thanks for the work.
I have some issues on my site, and am trying to reduce the PHP Warnings like :
[24-Nov-2023 15:46:25 UTC] WordPress database error You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ‘) ORDER BY price_per_distance DESC LIMIT 1’ at line 10 for query SELECT * FROM wp7f_drs_product_rules as t WHERE (t.min_distance < 0 OR t.min_distance = 0) AND (t.max_distance > 0 OR t.max_distance = 0) AND (t.min_order_amount < 4629 OR t.min_order_amount = 4629) AND (t.max_order_amount > 4629 OR t.max_order_amount = 4629) AND (t.min_order_qty < 1 OR t.min_order_qty = 1) AND (t.max_order_qty > 1 OR t.max_order_qty = 1) AND (t.min_order_weight < 0 OR t.min_order_weight = 0) AND (t.max_order_weight > 0 OR t.max_order_weight = 0) AND () ORDER BY price_per_distance DESC LIMIT 1 made by require(‘wp-blog-header.php’), require_once(‘wp-includes/template-loader.php’), do_action(‘template_redirect’), WP_Hook->do_action, WP_Hook->apply_filters, WC_AJAX::do_wc_ajax, do_action(‘wc_ajax_update_order_review’), WP_Hook->do_action, WP_Hook->apply_filters, WC_AJAX::update_order_review, do_action(‘woocommerce_checkout_update_order_review’), WP_Hook->do_action, WP_Hook->apply_filters, Coderockz_Woo_Delivery_Public->coderockz_woo_delivery_refresh_shipping_methods, WC_Cart->calculate_shipping, WC_Shipping->calculate_shipping, WC_Shipping->calculate_shipping_for_package, WC_Shipping_Method->get_rates_for_package, Distance_Rate_Shipping_Method->calculate_shipping, Distance_Rate_Shipping_Method->calculate_cost, Distance_Rate_Shipping_Method->get_matching_product_rules
The null And(), AND () ORDER BY seems to be the problem.
Can you please fix that, so we don’t have to keep editing it? And/or let us know the fix?
- The topic ‘Database Warning’ is closed to new replies.