Welcome Guest, Not a member yet? Register   Sign In
HELP w/SQL Server 2012 and insert_id

I have a piece of code:
PHP Code:
$new_id        $this->db->insert_id(); 

For SQL Server 2012, the $new_id suddenly stopped working, the record is inserted, but I am not getting back the newly created ID.

2 questions:
1) Any ideas how to fix this?
2) How bad would it be to use:
$this->db->query('Select MAX(ID) from table')->row()
in this instance?

I am using the MSSQL db driver:
'dbdriver' => 'mssql',
'dbprefix' => 'frontend.',

Theme © iAndrew 2016 - Forum software by © MyBB