Sql Postgres Rows Between Causing Duplicates Stack

Sql Postgres Rows Between Causing Duplicates Stack