what is the number of valence electrons of sodium carbonate?
Sodium carbonate is an compound and does not have valence electrons.
If you want to know about oxidation states of the constituent atoms they are as follows.
Na2CO3
CO3 has -2 charge i.e. CO3-- oxidation states = 3xO = -6 (as O has -2 oxidation state) therefore C has +4 (-2 charge on the ion)
As Na always forms a Na+ ion, there are two Na ions in the compound. Oxidation state of Na = +1