I know there is a skill called lucid dreaming from the Manual of the Planes...
Then there is Prophetic Dreamer from the netbook of feats.
PROPHETIC DREAMER [General]
COPYRIGHT 2001, Sigfried Trent
Your dreams sometimes echo the future
Prerequisite: DM’s permission
Benefit: Once per session, your GM should inform you of a dream you have had that portents an event that may be in your future. Ideally this dream could warn you of a possible danger, or guide you to a good decision. The dream need not come true, but should be a possible or likely scenario in the characters future. Sometimes the dreams are literal and sometimes symbolic, (at the DM’s discretion).
Notes: This feat isn’t for everyone. It should benefit the character but only as much as the DM wants it to. This could be a trait or the GM could decide some mystical event allows the character to start having these dreams.