Selection from New Jerusalem and Its Heavenly Doctrines ~ Emanuel Swedenborg
Ye shall do no unrighteousness in judgment: thou shalt not respect the person of the poor, nor honour the person of the mighty: but in righteousness shalt thou judge thy neighbor. (Leviticus 19:15)It shall first be shown what the neighbor is, for it is the neighbor who is to be loved, and towards whom charity is to be exercised. For unless it be known what the neighbor is, charity may be exercised in a similar manner, without distinction, towards the evil as well as towards the good, whence charity ceases to be charity: for the evil, from benefactions, do evil to the neighbor, but the good do good.
It is a common opinion at this day, that every man is equally the neighbor, and that benefits are to be conferred on everyone who needs assistance; but it is in the interest of Christian prudence to examine well the quality of a man's life, and to exercise charity to him accordingly. The man of the internal church exercises his charity with discrimination, consequently with intelligence; but the man of the external church, because he is not able thus to discern things, does it indiscriminately.
The distinctions of neighbor, which the man of the church ought altogether to know, are according to the good which is with everyone; and because all good proceeds from the Lord, therefore the Lord is the neighbor in the highest sense and in a supereminent degree, and the origin is from Him. Hence it follows that so far as anyone has the Lord with himself, so far he is the neighbor; and because no one receives the Lord, that is, good from Him, in the same manner as another, therefore no one is the neighbor in the same manner as another. For all who are in the heavens, and all the good who are on the earths, differ in good; no two ever received a good that is altogether one and the same; it must be various, that each may subsist by itself. But all these varieties, thus all the distinctions of the neighbor, which are according to the reception of the Lord, that is, according to the reception of good from Him, can never be known by any man, nor indeed by any angel, except in general, thus their genera and species: neither does the Lord require any more of the man of the church, than to live according to what he knows.
(New Jerusalem and Its Heavenly Doctrine 84 - 86)