I have a table in my mySQL database consisting of a number of fields including two date fields.
In a page I perform an update changing the value of one field, however the update also changes the value of the first date field to NOW() (i.e. today's date). It doesn't however update the second date. The only way I can get it to stop it is to update the date field setting it to itself (e.g.)
UPDATE tblBookings SET status='B' AND BookingDate = BookingDate WHERE BookingID='1'
I'm pretty sure I have checked everything I can think of, there seems to be no difference between the date fields and there is no default set up on either field. Also, (although I don't know if this is significant) if I go to the table in phpmyadmin and try to update the row the value in the listbox for that field is automatically set to NOW() but not for the second date field.
I hope that makes sense
Phil Clare
In a page I perform an update changing the value of one field, however the update also changes the value of the first date field to NOW() (i.e. today's date). It doesn't however update the second date. The only way I can get it to stop it is to update the date field setting it to itself (e.g.)
UPDATE tblBookings SET status='B' AND BookingDate = BookingDate WHERE BookingID='1'
I'm pretty sure I have checked everything I can think of, there seems to be no difference between the date fields and there is no default set up on either field. Also, (although I don't know if this is significant) if I go to the table in phpmyadmin and try to update the row the value in the listbox for that field is automatically set to NOW() but not for the second date field.
I hope that makes sense
Phil Clare