Welcome Guest, Not a member yet? Register   Sign In
insert date
#1

[eluser]r@mtbb_[/eluser]
Hi,

I'm trying to insert the current date into a mysql table and I'm doing something wrong.
Code:
$input = array(
    'title'            => $title,
    'description'             => $desc,
    'tag'             => $tag,
    'attachment'            => $file,
    'max'            => $max,
    'date'            => 'NOW()'
    );
$this->db->insert('some_table',$input);

The other variables are well inserted. The date field is "datetime" and remains null. What am I missing? Thanks!


Messages In This Thread
insert date - by El Forum - 12-30-2007, 04:14 PM
insert date - by El Forum - 12-30-2007, 07:56 PM
insert date - by El Forum - 12-30-2007, 09:00 PM
insert date - by El Forum - 12-30-2007, 11:17 PM
insert date - by El Forum - 12-31-2007, 02:30 AM
insert date - by El Forum - 04-19-2008, 12:32 AM
insert date - by El Forum - 04-19-2008, 02:03 AM



Theme © iAndrew 2016 - Forum software by © MyBB