The dolphin stranded on the beach is the one that we saw it yesterday in shallow water.
The dolphin stranded on the beach is the one that we saw yesterday in shallow water.
In the first sentence, the pronoun it and the pronoun that cannot be used in the same clause to refer to the same antecedent, one. The second sentence contains no unnecessary repetition.
For more help, see section 30d.