In both cases, the gas evolved is H2. When calcium reacts with water the heat evolved is not sufficient for hydrogen to catch fire. On the other hand, sodium metal reacts with water violently and in this case, a lot of heat is evolved which is sufficient for hydrogen to catch fire.