At this stage, in the effort to be perfect, your child may want things to go his way always. Reality can be the opposite. This can result in showing his frustration in the form of self-criticism and self-anger. In the long run, this can highly damage his self esteem and as a parent it’s hard to see your child in this situation.
What you need to do
By being empathic and listening to your kid with undivided attention, you can help him to vent his feelings. Next, try to make him understand what perfectionism is all about. For instance, if your child is upset about missing the first position in the class, you can say, "Such situations come and provide an opportunity to do better next time. Instead of getting upset, commit yourself to working hard."
If your child uses words like, " I am a failure or I can't do anything right", encourage him to say, "I did my best" or “I will perform better next time". Replace all his negative thoughts with positive self-statements. Get him into the habit of doing this, and self criticism will be replaced by positive thinking.
With perfection come positives like drive, energy and taking care of each and every detail. Encourage these positives in your child and reduce the negatives by promoting self compassion and acceptance.