I have a SQL2K instance that has granted me access through an unusual setup.
The SQL2K instance has granted me access through BUILTIN\Administrators by
including "NT_Authority\Authenticated Users" as part of that Windows Group.
Based on that, using DMO and C#, I need to be able to determine the default
database context. Normally, using DMO, you can access the Database property
off of the Login object, however, since my login name "DOMAIN\lgrissom" is
NOT explicitly defined anywhere, that won't work. Any ideas appreciated.
Lee
I found "SELECT DB_NAME()" T-SQL command, and used ADO.NET to execute that
against my ADO.NET connection instead of relying on my hidden DMO
connection. Works great.
Lee
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment