I have a vacuum cleaner that has an attachment called "power claw". It's basically a spinning brush powered by the airflow. It works great on our stairs, which are carpeted with cat hair.
One thing you can try is go pick up a 'slicker brush'. It's used for dog grooming, and they aren't very expensive. It should have more grip than the fabric the hair is stuck in. Of course, you're going to be picking the hair out of the brush. I like to use a fork to get the hair out. So brush the dog (or carpet) and when it starts to fill up with hair, use the fork to push the hair off the brush.