Take queryLayers column into account