How to fetch datetime field and it's score field form patient_profile model

How to fetch datetime field and it’s score field form patient_profile model each hour and display it in one2many field. Then display the sum for each day.
Give any reference for the code.

Any help will be appreciable.

What do you mean by “fetch”? What is “score” field?

Sir, fetch here denotes get the datetime entries saved by the user and score is the field inside the model who’s data we need to fetch and sum each entry saved by the user.