Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Tabish Rafique
5,913 PointsImplementation recurring fee system
I am developing a web application for a school. Record of Student monthly fee whenever its received from guardian will be added to it. I have created a class table and session table. A class will have session. Like Class Two (Session 2014) I want to implement such functionality that if fee of any student is not received for current active session then student should be listed separately. How can i achieve this. Do i need to add all fee records for session lets say 12 records for a complete year then loop through each if that fee has been paid or not. Is there any other better approach to achieve it?
1 Answer
Caleb McElroy
Courses Plus Student 12,953 PointsThis question is two weeks old I'm not sure if you've figured it out or not but I will respond incase another student has a similar question.
Though I'm not sure I understood your question exactly I will do my best to answer.
If you need to seperate certain records paid on if the status of is "received" or "not recieved" then mark that in your database. Then when you need to different lists (One: fee recieved, Two: fee not recieved) you can write an appropate SQL query to get two arrays that have the two lists and then process the arrays as needed.
Hope this helped & best of luck on your web app!