How to update db values from server side . without calling api (no cron job )

Viewed 13

I have contest application i want to update question index on that questions end time . and at last i want to audit that contest from live table to audit table . But all Tasks like update and delete should run from server side . if no player is live then also it should update question index at particular time . i don't able to figure out how can i perform this task . the contest end time is also stored in db table i need to run task that should update index at each question end time .

  contest.LivecontestTime = request.body.LivecontestTime
  contest.LiveQuestionIndex = request.body.questionIndex

Right now i'm getting index from client side because of that only when no user is playing the contest the question index is not updating .

0 Answers
Related