COmpletion of pagination