Why would HR ask me for my school qualification after 5 years of employment at the same firm?

HR ask you your school qualification after 5 years of employment at the same firm for various. I can only speculate not having spoken to your HR.

1). They have lost their employers' record, and want to retrieve this for their system - Administrative recording-keeping purposes.

2). They may be thinking of promoting you, and the to confirm that you have got the educational background for this, since the personal information of their staff have gone missing for various reasons.

3). They may be thinking of sending you for further training and wants to ensure that you meet the age and entry requirements.

4). HR may want to grade thrir staff and base this on the staff educational qualification.

Whatever, are the reasons may be, you should be quite safe, since, you have worked there for the last 5 years, and you are still enployed by them.