Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Returns the ___domain name and user name of the current connection.
Syntax
UserName [ ( ) ]
Remarks
The returned value is a string with the following format:
___domain-name\user-name
Example
The following example returns the user name of the user that is executing the query.
WITH MEMBER Measures.x AS UserName
SELECT Measures.x ON COLUMNS
FROM [Adventure Works]
See Also
Reference
Help and Information
Getting SQL Server 2005 Assistance
Change History
Release | History |
---|---|
17 July 2006 |
|