I can think of two separate topics for which I have successfully ordered myself to stop dreaming about them.
I had read, back when I was in grade school, that if we wait until we have fallen partly asleep, but still have some conscious-mind activity going on, we can ORDER ourselves to not dream of an unwanted topic, to dream about a workable solution for an existing problem, or to remember something like where we've put a misplaced item, etc. It's because our subconscious is starting to rise up to take over the job from the conscious mind when we are in that half-awake state. When we deliver these orders, our subconscious mind will take those marching orders and run with them.
The first time I did this, I wasn't allowed to have a pet (thank God my mom relented some years later). So every time I dreamed that I had a pet, then woke up to no pet, I would be upset. I ordered myself, "No more dreaming about having pets" using this technique. And it worked to the point where even now, in middle age and with 40+ years of having pets in my life, I STILL rarely dream of my pets. Heck, I want to undo the no-pet-dreams order, and I haven't figured out a way to do it yet.
The second time I used this successfully was in the aftermath of a mugging. (For which I hope the karma bus rolls over the perpetrator, but I digress.) About a month after the event, I had a bad dream where I was being mugged, from which I woke up. In my still-half-asleep state, I emphatically thought, "Oh, no you don't. It was bad enough I had to live through that once. This is NOT going to happen again. No more dreams of muggings!" It worked.
So I would recommend, if nightmares are happening regularly, doing this with an order of "I will have ONLY uplifting, enlightening dreams. Nightmares are DONE. Only good, healthy, positive dreams will happen from now on." But don't just think these things in a relaxed way -- ORDER this to happen, emphatically.
Let us know how this works out. I can only say that I have had success with the technique.
Visit The Lightworker's Sphere
on Etsy for my handmade wands, metaphysical gemstone jewelry, and meditation binaural/isochronic audio files. Visit my MP link (on the profile under my userID) for the spelled items that Etsy deemed too hot to handle!
I look forward to seeing you there!