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).

Did you know?Explore Trending and Topic pages for more stories like this.
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

socket makes browser hang...
I have a socket server, and I am having a problem at the moment...

A browser sends a http hea

Preventing SQL Injection
I have a question about SQL Injection, In some of our code we use this: view plaincopy to clipboa

Convert array to string and write to csv file
I am looking to write a MySQL query to a csv file.

At the minute I:

check for the orig

Call to undefined function mysql_fetch_accoc()
New to php/mysql coding. What's wrong with this sequence, or am I
just not seeing to obvious?

regex for quoted text within a string
I am still getting the hang of regex expressions, but I cant seem to figure out how I would escape q

Delete all files in folder except with certain name
I have a script that I want to delete all files in a folder (taken from a database) except for one n

script is pulling more then they have....
I have this script for my game where they can change there race. This will cost them 2,500 points. H

Need help making login verification cleaner...
I use the below to verify user login. I first check the cookie for the id, ip and a unique id. If it

chat
hello i'm amir i need a chat source code in asp.net 2.0 without Ajax. anybody can help me?

DYNPRO_FIELD_CONVERSION
Hi gurus,

I got a dump when I run one of my program. the dump is described below:

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