SQL Insert question
Posted: Fri Jul 28, 2006 12:02 pm
Hi,
I'm wondering why this query won't work:
I recieve the error: Out of range value adjusted for column 'last_active' at row 1
last_active is a mediumint(12). I've even tried it as an unsigned field, but it won't work. The value I'm trying to insert is simply the result from time();
Any help would be appreciated.
klarinetking[/syntax]
I'm wondering why this query won't work:
Code: Select all
$sql = "INSERT INTO `sessions` (`session_id`, `last_active`, `user_id`)
VALUES ('$this->sid', '$this->time', '29')";last_active is a mediumint(12). I've even tried it as an unsigned field, but it won't work. The value I'm trying to insert is simply the result from time();
Any help would be appreciated.
klarinetking[/syntax]