2w 2d old baby

Sarah
My baby had some congestion and a little raspy cry, but it's better. I recently switched her to enfamil gentlease and her poops are green and sometimes with some yellow in it, but now she's starting to cry when she's pooping, but the poop isn't solid. They come out either thick and creamy or when she farts, they'll splatter.. if that makes sense. Could she be getting sick or is it the formula? How will I know if she has a milk allergy?