Hello,
You can give Bevon syrup for now , it will help ease the pain to an extent only since it is basically a multivitamin syrup.
For ulcers, mucopain gel or hexigel provides better relief.
Next Steps
Visit a Paediatric Dentist as soon as possible.
Health Tips
Home remedies such as applying Glycerine to the affected area would help in the meantime.