I am Dr. Atul Kumar Nimawat, MS ENT.
Your history of persistent cough for 3 weeks associated with cold and productive mucus, along with paroxysms of cough leading to post-tussive vomiting, indicates that this is more than a simple viral upper respiratory infection. Since antihistamines and over-the-counter cough syrups have not provided relief, possibilities such as chronic bronchitis, post-nasal drip due to sinusitis, pertussis-like illness, or even gastroesophageal reflux exacerbating the cough need to be considered.
Next Steps
Since your symptoms are persisting beyond 2–3 weeks and are severe enough to cause vomiting, I strongly recommend consultation with nearest ENT or chest physician for further evaluation and targeted treatment.