I have been struggling with this question for a while and would like some scriptural help on the matter. I am married but keep having dreams about previous relationships that do not mean anything to me anymore. I love my husband and he is the only one I love. We have a happy, healthy marriage, and I feel so blessed! But for some reason I keep having sexual dreams about these past relationships. I just would like to know if I am committing a sin when I am having dreams about these things. Believe me if I had a choice to not dream about this I would and only dream about my husband. In fact that is all I want! †When I am having these dreams I do try to wake up from them as well. Thank you for your help, your answers are always to the point and scriptural. †
In some ways you need to see your brain as a machine. It is a device that stores and retrieves memories as well as preforming many other functions. But the brain is not you; that is, it isn't your spirit, though we have a difficult time distinguishing the two. "Now may the God of peace Himself sanctify you completely; and may your whole spirit, soul, and body be preserved blameless at the coming of our Lord Jesus Christ" (I Thessalonians 5:23). The brain is a part of the body, not the spirit.
Your brain takes in mountains of information each day and each night as you sleep it organizes the day's events for easy retrieval by connecting various old ideas to new ones. It's filing scheme is very loose, which is why you see something and suddenly remember something else that is totally unrelated. But there is also some logic to its filings. When you dream, you are watching the memories being connected, which is why dreams are so odd and disjointed.
Understanding this then gives a clue to what is happening in your dreams. The pleasures of your marriage are being connected to the disappointing relationships of the past, perhaps as a way to easily contrast the two. What is annoying is that you can't control this filing system, at least not directly. Because of that, realize that you are not sinning, but your past mistakes are being replayed and combined in odd ways to your present. That isn't your conscience mind at work, but the machine that is your brain.
Your rejection of these connections trains your brain to not make certain connections. And connections that are not used fade over time. Thus, if you focus on these dreams and the past events, they are kept fresh. If you dismiss them and refuse to focus on them during the day, they will fade as unused connections get pruned.
Job had a similar problem. He wanted to forget his misery, but his dreams brought the past back up. "When I say, 'My bed will comfort me, my couch will ease my complaint,' then You scare me with dreams and terrify me with visions, so that my soul chooses strangling and death rather than my body" (Job 7:13-15). He wrongly blamed those dreams on God, as we see later in the book, but we can sympathize with the fact that you can't control your dreams.
Thank you for writing a response. This makes me feel a lot better about the situation. I will work on trying to not dwell on it as much to try and eliminate the cause. Thanks again!