Being a writer is a great way of making a living but it can be horrible for your ego. Whatever you may achieve there's someone who has either achieved more, or is keen to belittle your work. I bet even JK Rowling gets twinges of writer envy when she looks at the literary review pages or hears her work being described as derivative. (I wonder if, as a children's writer, she ever gets asked when she's going to write a 'proper' book.)
Writing is a business where you're expected to promote yourself and part of that is keeping your failures to yourself. I learned that the hard way early on in my career when I had a dodgy moment. I told a few people, most of whom were sympathetic but one writer went out of her way to loudly commiserate at a publishing function in front of a lot of people who didn't know. It hurt.... I now keep my mouth shut if things aren't going to plan.
I suspect others do the same. It's therefore easy to think everybody else is swanning through the publishing world drinking champagne, and feel depressed as a result or succumb to a bout of writer envy. But I think everybody has their ups and downs. The person who signs with a top agent or gets a great deal - it may look easy but you don't know how many rejection letters they've received.
The best thing is to try not to let it affect you. We're not in competition. Their success does not lessen your own chances. But, gosh, I know it's hard. I've got four mates who all started writing at about the same time as me. They haven't - yet - had success with their novels, though two have just secured agents (yippee!) but they have been hugely supportive to me without a sign of writer envy. (Perhaps they're just nicer than I am!) Rachel, Sue, Linnet, Nancy - thanks and I wish you every success in the world.