Really expensive yogurt in good health food stores will add some back in after pasteurization, but those pills you took had billions of organisms in them
and the
yogurt not so much.
Yogurt is, though, as with other fermented
and cultured foods, a good prebiotic. But it's also dairy, and for most people that might make any digestive problems worse. Just depends on the person.