fixed bug in prev and next relations identified by Harish