Hi everyone. I needed some insight on how to structure a database for a project. The project is basically a school management application made using the mern stack. I have already inserted preexisting data for 1400 students. The students are divded in class prep, nursery, 1 - 10. Every class has 4 sections A to D. Every class has a particular fee associated with it. In the application i would want to add and remove students from a class also classs would change after a student successfully passes the session. I would want to gather and update fee payment history. I would want to calculate expenses and do some analytics about the budget. Focusing just on the fee collection how should I go about structing the database. Should i make a collection of classes with the relevant sections and fee. When the students pays the fee how would I go about storing the data should I create a hasPaid field that accepts a boolean for every student in the collection or make a field that holds an array of student fee information. How should I index the db without affecting performance.
Some insight on the matter would mean a lot for me.
Thanks in advance