Welcome Guest, Not a member yet? Register   Sign In
You must use the "set" method to update an entry on empty insert
#1

[eluser]Alsciende[/eluser]
Hello,

CI throwed the Database Error :

Quote:You must use the "set" method to update an entry

because I was trying to insert() an empty array in a table. Test case:

Code:
$this->db->insert('mytable', array());

It seems to me that the error message is misleading. Since my actual code wasn't as dumb as the above test case, it took me a while to figure out that my array was empty.


Messages In This Thread
You must use the "set" method to update an entry on empty insert - by El Forum - 03-21-2011, 05:59 AM



Theme © iAndrew 2016 - Forum software by © MyBB