Re: SQL Server Express 2005 @@SPID
am 22.11.2007 23:45:49 von Erland Sommarskog
Yoda (rmotto@teaminf.com) writes:
> which is the syntax for a stored procedure that return to me the exact
> @@SPID of my current connection?
>
> I'm using ADO in VB6 and i want to obtain @@SPID
CREATE PROCEDURE get_spid @spid OUTPUT AS
SELECT @spid = @@spid
--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downlo ads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books .mspx