mssql_rows_affected

(PHP 4 >= 4.0.4, PHP 5, PECL odbtp >= 1.1.1)

mssql_rows_affectedReturns the number of records affected by the query

Warning

This function was REMOVED in PHP 7.0.0.

Alternatives to this function include:

说明

mssql_rows_affected ( resource $link_identifier ) : int

Returns the number of records affected by the last write query.

参数

link_identifier

A MS SQL link identifier, returned by mssql_connect() or mssql_pconnect().

返回值

Returns the number of records affected by last operation.

范例

Example #1 mssql_rows_affected() example

<?php
// Delete all rows in a table
mssql_query('TRUNCATE TABLE [php].[dbo].[persons]');

echo 
'Deleted ' mssql_rows_affected($link) . ' row(s)';
?>

相关文章
php ibm db2 函数 returns the number of fields contained in a result setphp ibm db2 函数 returns the number of rows affected by an sql statementphp frontbase 函数 returns the error number from previous operationphp firebird/interbase 函数 return the number of rows that were affected by the previous queryphp informix 函数 get number of rows affected by a queryphp informix 函数 returns the number of columns in the queryphp ingres 函数 get the number of rows affected or returned by a queryphp maxdb 函数 returns the number of columns for the most recent queryphp maxdb 函数 returns the number of warnings from the last query for the given linkphp msql 函数 returns number of affected rowsphp mssql 函数 returns the next batch of recordsphp mssql 函数 returns the number of records affected by the queryphp mysqlnd qc 函数 returns information on the current handler the number of cache entries and cache entries if availablephp paradox 函数 returns number of fields in a databasephp paradox 函数 returns number of records in a databasephp session pgsql 函数 returns number of errors and last error messagephp sqlite 函数 returns the number of rows that were changed by the most recent sql statementphp sqlite 函数 executes a query and returns either an array for one single column or the value of the first rowphp sqlsrv 函数 returns the number of rows modified by the last insert update or delete query executedphp sybase 函数 gets number of affected rows in last query
关注编程学问公众号