Ma il dato calcolato lo salvi da qualche parte ?
Codice PHP:$this->sql = "SELECT codice FROM accettazione ORDER BY id DESC LIMIT 1";
if ($result = $this->hookUp->query($this->sql)) {
if ($result->num_rows > 0) {
while ($rw = mysqli_fetch_array($result, MYSQLI_BOTH)) {
$codice = $rw['codice'] + 0.00001;
...
Poi il codice che usi per aggiornare la tabella.
}
} else {
echo date("Y") . ".00001";
A che cosa serve questo ?
}
} else if ($this->hookUp->query($this->sql) === false) {
echo "fail";
}


Rispondi quotando
