If you cannot change the value of your heap, try this
Add this to mysql / etc / my.cnf
[mysqld] tmp_table_size=2G max_heap_table_size=2G
this will include mysql restarts. To set these values ββin mysqld right now without restarting, run this:
SET GLOBAL tmp_table_size = 1024 * 1024 * 1024 * 2; SET GLOBAL max_heap_table_size = 1024 * 1024 * 1024 * 2;
If you check the above variables with
SELECT @@max_heap_table_size;
you may notice that they do not change after the SET GLOBAL...
statements. This is because the settings apply only to new connections to the server. Create a new connection and you will see the value update.
source share