|
Hello! My company have created a website where employees will be able to take a test to earn points (CPD hours) which will be updated every time an employee takes the test. I am trying to find a way to update the number of CPD hours each employee has earned by using SQL, and displaying this on their profile page. The number of CPD hours awarded will need to be updated every time they earn more points. Every time they take the test, 2 CPD hours will be added. Any help on this would be much appreciated! :) Thanks!
(comments are locked)
|
|
If it's as simple as updating the hours each time they take the test, then you could update their hours in the data table by using something like: This works perfectly, Thanks for the help! :)
Jan 17 '12 at 05:43 AM
Amber-Rose
If the CPD hours are actually significant in some way, it may be worth also having an audit/log table tos how when and why the hours got changed.
Jan 17 '12 at 10:38 AM
TimothyAWiseman
(comments are locked)
|
|
And in addition to what @ThomasRushton says, you need to have the web page run a query to retrieve the data from the database. Then, as the data gets updated, the web site will as the pages load. Thank you too! :)
Jan 17 '12 at 05:53 AM
Amber-Rose
(comments are locked)
|

