diff --git a/system/database/DB_driver.php b/system/database/DB_driver.php
index 22f91ed..a4131fd 100644
--- a/system/database/DB_driver.php
+++ b/system/database/DB_driver.php
@@ -172,6 +172,7 @@
$CI =& get_instance();
$CI->dbutil = new $class();
+ $CI->_ci_assign_to_models();
}
// --------------------------------------------------------------------
@@ -629,7 +630,7 @@
*/
function primary($table = '')
{
- $fields = $this->field_names($table);
+ $fields = $this->list_fields($table);
if ( ! is_array($fields))
{