Current location - Training Enrollment Network - Mathematics courses - Php, database, how to perform mathematical operations on the return value
Php, database, how to perform mathematical operations on the return value
$ SQL = " SELECT COUNT(*)AS COUNT FROM mark WHERE hID = ' $ hID ' ";

$ result = MySQL _ fetch _ array(MySQL _ query($ SQL));

$ count = $ result[' count '];

$ count++;

$ numOfScore = $ count$ COUNT = MySQL _ result(MySQL _ query(" SELECT COUNT(*)AS COUNT FROM mark WHERE hID = $ hID "),0);

$ numOfScore = $ count+ 1;