Anxiety and depression about the future of my PhD study I did my master in one lab and am continuing my PhD here. My advisor asked me to do some research that he doesn't know, and is also beyond the domain of my current major. I have no other choices so I did some work in my master. Because I haven't gotten any professional advice on that kind of research, I am very unsatisfied with my previous work, but I graduated anyway.

Now I am becoming a new PhD student in the same department and same lab. And I'm facing the PhD qualifying exam. I've always been thinking about doing something new so that I can pass the qualifying exam. But since my advisor is still asking me to do the same kind of research and he's still not providing any professional help, I made very little progress.

Now the PhD qualifying exam is impending. On the one hand, I need to continue my research, which is still very hopeless; on the other hand, I have to review some class materials to prepare for the exams. And I'm still taking a class.

I feel so overwhelmed and am currently very anxious and depressed. Sometimes when my mood is very bad, I start to hate my advisor deep in my mind. My advisor wanted me to do that kind of research simply because he thinks that is interesting, but he actually does not know much about it because that is beyond his research area. Worse still, he is the kind of professor who forbids collaborations even among his own group.

Because the research he asked me to do is beyond my previous experience, I have to go slowly solely by myself. I have to take relevant classes and read papers that I usually find hopeless to understand. (Now it's much better, I can understand most of the papers.) What I found was that usually it took me a lot of time only to figure out that the way I was thinking simply didn't work. As a result, I wasted so much time in this way. I mean, I was just a master student before, should I master student be required to do that kind of things?

Now my confidence is running out. I basically achieved nothing in my master, and it will be very hard for me to even pass the PhD qualifying exam. Because the exam is impending, changing advisor is almost impossible, partly because my advisor will be the one who at least has power in determining whether I should pass or not.  Also, it is very hard to find a new advisor in my current university, both because of the environment of the department culture and my previous achievements on research.

Yes, everything is bad about me, but that's where I am. Any advice on helping me to get out my current dilemma will be appreciated.
My advice would be to find another advisor, maybe even a different university. If you are just at the beginning, then it is a good time to move. 

There is very little worse than an unsupportive advisor. 

But if you think it is possible to move, look among the faculty for one or two people who believe in you and can support and application elsewhere. With good support it may be possible to move even if you need to take the qualifiers and do poorly. Your advisor is probably not the one to help you. 

Even at the same institution it may be possible to reset the clock on your exams if you move to a different advisor. Sometimes the department head can help and sometimes you just work through a more compatible faculty member. 

But continuing on doesn't seem like it is going to be easy, maybe not even possible. Look to your options. 

One good thing that has come out of it is that you have learned to read and understand the literature. That is an important and useful skill. 

However, if you are overly stressed and seriously depressed, you should seek medical advice, and learn about stress reduction activities.