AJ, primers, as BJ said, are problem solvers. I have raw wood or drywall, and since finish is not designed to bond to those substrates, that's a problem. Primers are designed to bond to bare substrates, and have a higher resin content, but have less hide. Finishes have higher pigment content that gives the hide. There are numerous conditions and problems that can give a painter a flawed finish, either aesthically or functionally, and numerous types of primers to correct for those.
I've never used primer to hide color on a color change, and that's either on my own jobs or when I've worked for other pros, and that accounts for about twenty five years of rolling, or as BJ says, "rubbin" walls.
Unlike BJ, I carry three basic primers, Zinsser Cover Stain, Zinsser (shellac)BIN, and a regular everyday latex primer, usually Zinsser 123 or a BM or Sw primer. I think Cover Stain is the most universal primer, it seals and bonds, unlike Kilz, which doesn't bond. It can be used as a full prime both interior and exterior, unlike BIN which is full interior spot exterior. Though they may be spec'd for drywall, neither Cover Stain (oil) or BIN are ideal for priming new drywall, in which case I'll use the 123. However, if I have a job where I'm doing a lot of new drywall, I'll buy a conventional dedicated drywall primer. In some cases when I have a lot of new pine trim to prime I'll use full BIN to head off what nuclearnerd is suffering. There are a lot of variables, which could, yes, be a book.
I'm doing some Hurricane Sandy aftermath work in Ocean City, NJ. I'm working for the owner of the building/business, while a new tenant is remodeling undamaged office areas. The new tenant's contractor is doing his painting, and he's done nice carpentry work. However, when it comes to painting, he's a DIY. Part of their job is a stairway, which had wallpaper that was stripped, over plaster. The walls were not washed and were caked, and I mean caked, with wallpaper paste. Yesterday, his guy was rolling drywall primer on those walls. He had a problem, which he failed to recognize. And he didn't know he needed a special primer, either an oil quick dry or Gardz, to act as a barrier between the water soluble paste and water based topcoat. Now, his final finish, and the primer, is at great risk of complete failure as the paste can cause the whole job to end up a crackle finish and flake off. That's the difference between a pro and a handyman/DIY. The walls are such a mess that I recommended rehanging paper to the tenant, but he was being sentimental on paint, and his contractors cheaper paint bid. I told him, twice, that he needed an oil prime and extensive plaster repair and that paper was the easier/least cost way to go. Now his shortsightedness, and stinginess, may end up costing him dearly. Always hire a pro. I don't necessarily like it, but I'll struggle to hide my glee when the finish goes crackle and pop. Always hire a pro.