It starts with emotion and ends with etiquette. Where does it come from?

From the preface to Mao’s poems in The Book of Songs. The preface to Mao's poem "Bianfeng" says: "Therefore, the changing wind arises from emotion and ends with etiquette. It arises from emotion and is the nature of the people; it ends with etiquette and is the beauty of the previous king."

《 "The Analects of Confucius·Bayi" has: "Confucius said: 'Guanyong', happiness without being obscene, sadness without being sad.'" In one word, those who are sad and happy are "emotional"; but not obscene, not sad. Injury means "stopping from etiquette".

Both are poems with different tunes but similar results, so some people mistakenly believe that this sentence comes from "The Analects of Confucius".