add select related in sql