2
How do I change a record in my table and keep the date the record was created.
In the INSERT
I’m using the method now()
. When I wear one UPDATE
to change only one column the date is being changed, and I need to keep the date the record was created, tested first on phpMyAdmin
and then on my application, in both ways the date is being changed.
How is the
UPDATE
and how the column is defined?– Marcelo de Andrade
"UPDATE requests SET status='$status' WHERE id = '$id'"; The date column is of type: timestamp. In my case I need to update only the column "status".
– Clicnet
And which column is being updated together and should keep the creation date, as mentioned?
– Marcelo de Andrade
The "date" column was being updated and changing the record creation date and I just wanted to change the "status", but it was already solved with the @William Novak tip.
– Clicnet