Number of Undead Affected
If the attempt to turn undead is a success, 2d6 hit dice of undead monsters are affected. Surplus hit dice are lost (so if zombies are being turned for example--each with two hit dice--and a roll of 7 is made, at most three zombies can be turned). However, a minimum of one creature will always be affected if the first roll succeeds.
Multiple Groups of Undead
If a mixed group of undead (say, a wight and a pair of zombies) is to be turned, a single roll is still made. The result is checked against the weakest sort first (the zombies) and if they are successfully turned the same result is checked against the next higher type of undead.
Likewise, the 2d6 hit dice are rolled only once. For example, if the group described above is to be turned by a 2nd level cleric, he would first need to have rolled a 15 or higher to turn the zombies. If this is a success, 2d6 are rolled; assuming the 2d6 roll is a 7, this would turn both zombies and leave a remainder of three hit dice of effect. Wights are, in fact, three hit die monsters, so assuming the original 1d20 roll was a 20, the wight is turned as well. Obviously, were it a group of three zombies and a wight, the 2d6 roll would have to be a total of 9 or higher to affect them all.
Clerics can attempt to turn any remaining undead within the current encounter area once per combat round. Undead monsters which are turned are incapacitated for one hour and will no longer attack the adventuring party. In effect, they are defeated, and should all other enemies be defeated within the encounter, the battle will be over. Undead subject to the "D" result are immediately destroyed by the cleric and permanently removed from the encounter.