Welcome Guest, Not a member yet? Register   Sign In
mysqli $this->db->insert_id constantly returns 0

'save_queries' just adds the last executed query to an array, so that it can be later returned by last_query(); it doesn't affect anything else but memory usage.

In fact, having 'save_queries' turned on (which is the default, even when you don't have it in the config) may help you debug the issue ... Do a var_dump($this->db->last_query()) right before calling insert_id().

Does it show an INSERT query? If not, there's your problem.

Messages In This Thread
RE: mysqli $this->db->insert_id constantly returns 0 - by Narf - 05-29-2015, 06:44 AM

Theme © iAndrew 2016 - Forum software by © MyBB