MINOR Re-added in function_exists() for sqlsrv_num_rows() for backwards compatability with sqlsrv 1.0, added a warning that it'll only work on cursors other than forward only

This commit is contained in:
Sean Harvey 2010-05-19 12:13:33 +00:00
parent 888dc64c0a
commit a0768ec44d

View File

@ -1499,9 +1499,12 @@ class MSSQLQuery extends SS_Query {
if($this->mssql) {
return mssql_num_rows($this->handle);
} else {
// WARNING: This will only work if the cursor type is NOT forward only!
if(function_exists('sqlsrv_num_rows')) {
return sqlsrv_num_rows($this->handle);
}
}
}
public function nextRecord() {
// Coalesce rather than replace common fields.