changed SQL for MySQL check
because the old SQL requested some privileges