Fix querying tables with missing bucket columns