implement pagination in intermediate result grid