Hi,
In a Business Operation i have the following code.
I need the identity of the latest row inserted in a table in MSSQL.
i Have the following code:
---------------------------------------------------------
set insertmaster= "INSERT INTO dbo.dataMasterArchive(deviceToPatientLogID) values (?)"
set tSC = ..Adapter.ExecuteUpdate(.nrows1,insertmaster,pRequest.deviceToPatientLogID)
$$$ThrowOnError(tSC)
set sql ="SELECT SCOPE_IDENTITY()"
set tSC = ..Adapter.ExecuteQuery(.tResult,sql)
$$$ThrowOnError(tSC)
set maxID = tResult.Get(1)
------------------------------------------------