My 2 month old has had a cough and diarrhea for a couple weeks what could it be?

M.D. visit. It may be a prolonged viral infection which affects both the GI tract and lungs. I would suggest keeping your baby well hydrated and a visit with your pediatrician.
See your doctor. If she's had symptoms for that long, its time to see her doctor.