If the runny nose you have is due to a cold then you need a medicine that contains decongestant but if your runny nose is caused by allergies then you need an allergy medicine with antihistamines.
When my allergies are flaring up and I have a runny nose due to allergies then I take Zyrtec allergy medicine and it stops my runny nose.
For a cold and runny nose I take Sudafed which helps my running nose.
You can also get rid of a runny nose by flushing out your sinuses, taking a hot shower, using a humidifier or use a Neti Pot with a saline solution which will stop a runny nose.