Skip to content

Commit

Permalink
Fix #36632
Browse files Browse the repository at this point in the history
  • Loading branch information
wez committed Apr 30, 2006
1 parent aa5dbc8 commit 07e11dc
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions NEWS
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ PHP NEWS
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
?? ??? 2006, PHP 5.2.0
- Fixed bug #35552 (crash when pdo_odbc prepare fails). (Wez).
- Fixed bug #36632 (bad error reporting for pdo_odbc exec UPDATE). (Wez).

28 Apr 2006, PHP 5.1.3
- Updated bundled PCRE library to version 6.6. (Andrei)
Expand Down
8 changes: 8 additions & 0 deletions ext/pdo_odbc/odbc_driver.c
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,14 @@ static long odbc_handle_doer(pdo_dbh_t *dbh, const char *sql, long sql_len TSRML

rc = SQLExecDirect(stmt, (char *)sql, sql_len);

if (rc == SQL_NO_DATA) {
/* If SQLExecDirect executes a searched update or delete statement that
* does not affect any rows at the data source, the call to
* SQLExecDirect returns SQL_NO_DATA. */
row_count = 0;
goto out;
}

if (rc != SQL_SUCCESS && rc != SQL_SUCCESS_WITH_INFO) {
pdo_odbc_doer_error("SQLExecDirect");
goto out;
Expand Down

0 comments on commit 07e11dc

Please sign in to comment.