Added max query memory.