Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
[WooCommerce Bookings] Enable Big Selects to fix MAX_JOIN_SIZE errors
/**
* Will enable big selects when the host has a low threshold for MAX_JOIN_SIZE.
* This is sometimes the case with shared hosting.
*/
function enable_big_selects_for_bookings_20170825() {
global $wpdb;
$wpdb->query( 'SET SQL_BIG_SELECTS=1' );
}
add_action( 'init', 'enable_big_selects_for_bookings_20170825' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment