Melatonin is an odd one in terms of sleep aids. It seems not to be so much of a tranquillizer or hypnotic/sedative, but more of a regulator of circadian rhythms . I've tried it before, and for a time got it on RX. Couldn't really tell weather it was working or not. But it didn't seem to help with my sleep problem, that being a massive delay in sleep onset time, often as much as 6-7 hours before I'd fall asleep, at least, before I found the right combination of meds, which helps with that as a side effect.
The effects on dreaming were interesting though. Its triggered an OOBE once before, after smoking just a little herb whilst taking the melatonin.