Bulk insert query with datetime field |
HI,
I'm still struggle to insert bulk insert data with datetime column to database. Currently i'm using, if any datetime column in database means, the below codes i use $pub_contact_info = array( 'cc_contact_id' => $pub_contact_id, ); $this->db->set('cc_created_date', 'NOW()', FALSE); $this->db -> insert('ch_contact', $pub_contact_info); But, in batch insert means, how can i use NOW() in insert_batch() function Thanks in advance.
Try:
Code: $right_now = date("Y-m-d H:i:s"); Maybe not tested
Practical guide to IgnitedCMS - Book coming soon, www.ignitedcms.com
|
Welcome Guest, Not a member yet? Register Sign In |