Adding pagination constraints