Hi David, Thanks for reviewing my patch
> Is the patch an AI fix?... I recently used AI to verify all the assertions and find this issue then I picked that direction and had it draft V1. Then I tested it myself. > it's a pretty inefficient way to make it > work correctly. It seems wasteful to me to have to recreate the > tuplesort just because the boundedness requirements have changed Agree... I copied ExecReScanSort() for V1 and did not think about reusing the state. I also thought about doing the tuplesort_reset direction a little bit, but did not go with that direction. > Maybe in master we could adjust the tuplesort_reset() > function to take the allowbounded parameter. I think we should do that. I tested V2 locally and it looks good. Thanks, Shihao
