diff --git a/system/drivers/DB_odbc.php b/system/drivers/DB_odbc.php
index 50f39ac..a5a8db6 100644
--- a/system/drivers/DB_odbc.php
+++ b/system/drivers/DB_odbc.php
@@ -445,9 +445,16 @@
 	 */
 	function _fetch_assoc()
 	{
-		return odbc_fetch_array($this->result_id);
+		if (function_exists('odbc_fetch_object'))
+		{
+			return odbc_fetch_array($this->result_id);
+		}
+		else
+		{
+			return $this->_odbc_fetch_array($this->result_id);
+		}
 	}
-	
+
 	// --------------------------------------------------------------------
 
 	/**
@@ -460,9 +467,63 @@
 	 */
 	function _fetch_object()
 	{
-		return odbc_fetch_object($this->result_id);
+		if (function_exists('odbc_fetch_object'))
+		{
+			return odbc_fetch_object($this->result_id);
+		}
+		else
+		{
+			return $this->_odbc_fetch_object($this->result_id);
+		}
 	}
-	
+
+
+	/**
+	 * Result - object
+	 *
+	 * subsititutes the odbc_fetch_object function when
+	 * not available (odbc_fetch_object requires unixODBC)
+	 *
+	 * @access	private
+	 * @return	object
+	 */
+
+	function _odbc_fetch_object(& $odbc_result) {
+		$rs = array();
+		$rs_obj = false;
+		if (odbc_fetch_into($odbc_result, $rs)) {
+			foreach ($rs as $k=>$v) {
+				$field_name= odbc_field_name($odbc_result, $k+1);
+				$rs_obj->$field_name = $v;
+			}
+		}
+		return $rs_obj;
+	}
+
+
+	/**
+	 * Result - array
+	 *
+	 * subsititutes the odbc_fetch_array function when
+	 * not available (odbc_fetch_array requires unixODBC)
+	 *
+	 * @access	private
+	 * @return	array
+	 */
+
+	function _odbc_fetch_array(& $odbc_result) {
+		$rs = array();
+		$rs_assoc = false;
+		if (odbc_fetch_into($odbc_result, $rs)) {
+			$rs_assoc=array();
+			foreach ($rs as $k=>$v) {
+				$field_name= odbc_field_name($odbc_result, $k+1);
+				$rs_assoc[$field_name] = $v;
+			}
+		}
+		return $rs_assoc;
+	}
+
 }
 
 ?>
\ No newline at end of file