Easysoft Data Access
Why does SQLRowCount/odbc_num_rows and $sth->rows return -1?
odbc_num_rows
is the PHP wrapper for the ODBC API SQLRowCount. $sth->rows
is the Perl DBI method of obtaining the results from the ODBC API SQLRowCount.
Most ODBC drivers only return a meaningful number from SQLRowCount call when you execute row changing SQL e.g. UPDATES, DELETES, INSERTS. For SELECTS most ODBC drivers return -1
.
Applies To
-
Products
- Easysoft ODBC-Oracle Driver
- Easysoft ODBC-InterBase Driver
- Easysoft ODBC-Sybase Driver
- Easysoft ODBC-ODBC Bridge
- Easysoft ODBC-Firebird Driver
- Easysoft ODBC-ISAM Driver
- Easysoft ODBC-Zortec System Z Driver
- Easysoft ODBC-ODBC Join Engine
- Easysoft ODBC-RMS Driver
- Easysoft ODBC-CODA Driver
- Easysoft ODBC-SQL Server Driver
- Easysoft ODBC-Access Driver
- Easysoft ODBC-DB2 Driver
- Easysoft ODBC-Derby Driver
- Easysoft ODBC-Salesforce Driver
- Easysoft ODBC-MongoDB Driver
- Easysoft ODBC-Google Analytics Driver
- Easysoft ODBC-MySQL Driver
- Easysoft ODBC-QuickBooks Desktop Driver
- Easysoft ODBC-PostgreSQL Driver
-
Interfaces
-
Languages
Knowledge Base Feedback