A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://www.yiiframework.com/doc/api/2.0/yii-db-mssql-sqlsrvpdo below:

SqlsrvPDO, yii\db\mssql\SqlsrvPDO | API Documentation for Yii 2.0

Class yii\db\mssql\SqlsrvPDO

This is an extension of the default PDO class of SQLSRV driver.

It provides workarounds for improperly implemented functionalities of the SQLSRV driver.

Method Details

Hide inherited methods

lastInsertId()

public method

Returns value of the last inserted ID.

SQLSRV driver implements yii\db\mssql\PDO::lastInsertId() method but with a single peculiarity: when $sequence value is a null or an empty string it returns an empty string. But when parameter is not specified it works as expected and returns actual last inserted ID (like the other PDO drivers).

Source code

                #[\ReturnTypeWillChange]
public function lastInsertId($sequence = null)
{
    return !$sequence ? parent::lastInsertId() : parent::lastInsertId($sequence);
}

            

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4