In order to replace an Oracle DB with SQL-Server 2005 i need a unique session ID. The number Obtained by @@SPID is for reuse and does not meet my requirements. I'm looking for something like v$session.audsid in ORACLE.
Thanks
Raimund
In order to replace an Oracle DB with SQL-Server 2005 i need a unique session ID. The number Obtained by @@SPID is for reuse and does not meet my requirements. I'm looking for something like v$session.audsid in ORACLE.
Thanks
Raimund
Unique Session ID
John Askew
hi raimund
Auditing in sql server is done by running the sql profiler
and then storing the trace to a table or a file.
using the SQL Profiler
you can use a lot of counters such as
username, clientprocessid, spid, cpu,
object names counters and many more
Profiler can be run on a separate box
I hope it can contribute to your solutions
joey
abbarron
The main purpose of this Session-Id is to Check wether the Connection is alive or not. Further there sould be the possibility to log the Session in an kind of audit trail even if the connection itself isn't alive anymore.
Thanks
Raimund
Waiman Li
I dont know how oracle works.
but if you want something unique you can use this
DECLARE @myid uniqueidentifier
SET @myid = NEWID()
PRINT 'Value of @myid is: '+ CONVERT(varchar(255), @myid)
these are called GUIDS - globally unique identifier
Shivakumara V
Whatonly
i think you can also use
sp_who
Provides information about current MicrosoftR SQL Server users and processes. The information returned can be filtered to return only those processes that are not idle