This seems to happn when people up grade and something happened that the control panel settings did not update the tables . Even if the control panel looks correct submit the setting again. HERE is a similar post.
Blue Man Group There is no such thing as stupid questions. Just stupid answers
This specific error can usually be fixed by entering the CP and going to the gallery page and just submitting the form (don't have to update any info, just submit it as is with the defaults)