我有一个字段caloriesBurned
,可以跟踪总工时数。我想在这个字段中输入每日价值并让字段继续累计输入的小时数,即星期一2小时结婚2小时.. caloriesBurned
应填充4小时....这可能吗?这是我的代码。
$monthSum= mysql_query("SELECT caloriesBurned FROM workout WHERE userid = $userid");
$sql = mysql_query ("UPDATE workout SET caloriesBurned = SUM($monthSum($caloriesToday)) WHERE userid = $userid");