TimeStamp Column Problem...


Posted on 16th Feb 2014 07:03 pm by admin

I'm mad at my self and thinking I'm a little retarded. It just be some one mistake I'm missing here. I coded my self a forum, when you reply to a topic, the topic's TimeStamp column is supposed to be updated to the current timestamp. However I attempted and failed.

I put the timestamp column on "ON UPDATE CURRENT TIMESTAMP", I set the column to NULL but seems to be at the same value. The column isn't null. I don't know if I should or shouldn't do that. I'm a complete newbie at MySql(~1Month).

Code: $sql = mysql_query("UPDATE `threads` SET `last_post_user_id` = '$id', `time` = 'NULL'; WHERE `id` = '$forum_id'");

Thanks

No comments posted yet

Your Answer:

Login to answer
65 Like 22 Dislike
Previous forums Next forums
Other forums

Will an XHTML DOCTYPE interfere with my PHP if I'm not experienced enough?
I've read this article here: http://friendlybit.com/html/why-xhtml-is-a-bad-idea/

In a nutshe

C++ API to Oracle dB
I need to perform a select command to the Oracle dB to obtain information from a table.
What libr

Get last modified date of web page
Hai All,

In php how can i get last modified date of a give web page . I have tried to g

NOOB needs help with upload file
The intent of this form is to create a folder for a client and upload an image into another folder '

writing my own sobel filter convolution - something is wrong
I am trying to keep it very simple, I cant see anything wrong with my logic, could anybody help poin

Appending GET data with form submition
Okay, what I'm trying to do is to use a form to append an already existing GET data string.

I

Any decent php formatter/beautifier/pretty printer?
Any decent php formatter/beautifier/pretty printer class/function?

I found the following whil

Displaying data from MySql a different way
Hi all,
I'm pretty new to php and MySql and have hit a problem.

I am able to display data

PHP Tab Control
Hi All,

I would like to have PHP tab control with/without Javascript.

But I want to r

Just cannot get 'area' to submit to db using same php code as already used
Basically all i have done is just modified some code and added an area section.
The form is allre

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash