Even if you hate your job, here are some ways to deal with it
1. Dont let your job define you. Think about your job the way a teenager might think about his after-school stocking job at the grocery store.
2. Have a rich, active life outside the office. When not at work, fill every minute doing things you love. Don't sit at home on your couch thinking about how awful your job is.
3. View the position as a temporary state. Attend networking events and keep the channels open so that when you go back on the market, the transition will hopefully be a simple one into a new job.
4. When at work, act as if you love your job. It's the ol' "fake it, until you make it" mentality.