make the result better reflect size parameter

switch from QUERY_AND_FETCH to QUERY_THEN_FETCH, if in the future we want this service to be faster, we can consider switching back to QUERY_AND_FETCH