Do it after student. Because <dataroot> is the parent
like this
Code:
<?xml version="1.0" encoding="UTF-8"?>
<dataroot>
<STUDENT>
<NAME>Shan</NAME>
<AGE>22</AGE>
<SCHOOL>Elakiri</SCHOOL>
</STUDENT>
<STUDENT>
<NAME>John</NAME>
<AGE>25</AGE>
<SCHOOL>Royal</SCHOOL>
</STUDENT>
</dataroot>
if you are using a DTD file make sure it is defined properly.