MDL-33434 mssql: Improve handling of returned ids on insert.
commit87ba4ff25a40ecc3655ae056cee37d353705d2b1
authorEloy Lafuente (stronk7) <stronk7@moodle.org>
Wed, 30 May 2012 23:01:14 +0000 (31 01:01 +0200)
committerEloy Lafuente (stronk7) <stronk7@moodle.org>
Wed, 30 May 2012 23:49:48 +0000 (31 01:49 +0200)
tree2d93e626bb7da10319fe12fea681fc5cc503d6bb
parenta90655655437fc94610b865e7c213de48255731b
MDL-33434 mssql: Improve handling of returned ids on insert.

This commit moves from the batch SCOPE_IDENTITY() way to return
the inserted ids to the OUTPUT alternative (supported and
recommended since 2005). Also the handling of possible return
values is improved, with all the alternatives leading to expected results.
lib/dml/mssql_native_moodle_database.php