Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.5.0b4

Bug #7291 Use of @@IDENTITY
Submitted: 2006-04-04 16:23 UTC
From: james dot sapara+pear at gmail dot com Assigned: nrf
Status: Closed Package: MDB2_Driver_mssql (version 1.7.6)
PHP Version: 4.4.2 OS: Windows/Linux
Roadmaps: (Not assigned)    
Subscription  


 [2006-04-04 16:23 UTC] james dot sapara+pear at gmail dot com (james)
Description: ------------ It is possible that the use of @@IDENTITY will not return the expected value when there is a trigger present. The use of SCOPE_IDENTITY() is preferred in this case. file: mssql.sql line: 540 replace line: $result =& $this->query("SELECT @@IDENTITY FROM $seqname"); with: $result =& $this->query("SELECT SCOPE_IDENTITY() FROM $seqname");

Comments

 [2006-04-05 07:05 UTC] lsmith (Lukas Smith)
I will relabel this as an MDB2_Driver_mssql bug for now, as here is where most development is going on. We should first analyze the actual impact and then decide a fix that we will then backport.
 [2006-06-15 01:00 UTC] nrf at php dot net (Nathan Fredrickson)
This bug has been fixed in CVS. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better.