Besides the fact that it doesn't taste very good, drinking saltwater is a bad idea because it causes dehydration.
If you took a few gulps of ocean water, for example, your body would have to urinate more water than you drank to get rid of all that extra salt, leaving you thirstier than you were before.
Seawater can be desalinated to bring salt levels down to where they are palatable, but the technique is very energy-intensive.
Some animals have evolved ways to get around the problem of all that extra salt in sea water. For example, albatrosses have special salt glands just behind their eye sockets that take up the salt in the water a bird gulps and then secretes it in a salt solution that drains out through the tip of its beak.