Deuteronomy 5:9-10 NIV

9 You shall not bow down to them or worship them; for I, the LORD your God, am a jealous God, punishing the children for the sin of the parents to the third and fourth generation of those who hate me,

References for Deuteronomy 5:9

10 but showing love to a thousand generations of those who love me and keep my commandments.

References for Deuteronomy 5:10