Mahāsutasomajātaka

Suttapiṭaka · Khuddakanikāya · Jātaka (2) · Vol. 28 · Section 342

[342] "Even a single meeting with the good, O Sutasoma — that association protects one; not so much company with the bad. One should keep company only with the good; with the good one should form intimacy. Having come to know the true Dhamma (saddhamma) of the good, one becomes better, not worse. Royal chariots, beautifully adorned, indeed wear out, and the body too comes to old age; but the Dhamma of the good does not come to old age — the good, indeed, proclaim it among the good. The sky is far and the earth is far; the farther shore of the ocean, they say, is far; farther still than that, they say, O king, are the Dhamma of the good and that of the bad."

English translation from the Pali (Siam Raṭṭha edition) — under review, not for citation.

This passage also appears in 1 other place