A substance can have pharmacological effects and still not be recommended for therapeutic use. As a hyperbolic example, suppose a substance relieved all pain for 1% of the population but caused death in everyone else. Even with a highly precise screening process this substance likely would not be administered in medicinal contexts.