At the pituitary, it suppresses the release of both thyroid-stimulating hormone and growth hormone. It also acts as a neurotransmitter in the brain in other regards. Finally, it has a massive range of inhibitory action in the gastrointestinal tract. For instance, it inhibits the release of insulin, glucagon, gastrin and cholecystokinin, to name just a few things!
Octreotide, on the other hand, is a synthetic analogue of somatostatin. It has been used to treat acromegaly (i.e. the clinical syndrome of excess growth hormone production) as well as in carcinoid syndrome and oesophageal varices. It's not exactly the same thing as somatostatin (it has a greater blocking effect on insulin, glucagon and growth hormone than its natural counterpart), but it is closely related.