|
|
 |
BOOK: Professional SQL Server 2005 CLR Programming: w/ Stored Procedures, Functions, Triggers,  | This is the forum to discuss the Wrox book Professional SQL Server 2005 CLR Programming: with Stored Procedures, Functions, Triggers, Aggregates, and Types by Derek Comingore, Douglas Hinson; ISBN: 9780470054031 |
|
Welcome to the p2p.wrox.com Forums.
You are currently viewing the BOOK: Professional SQL Server 2005 CLR Programming: w/ Stored Procedures, Functions, Triggers, section of the Wrox p2p Programmer to Programmer discussion community. This is a community of more than 40,000 computer programmers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining our free Wrox p2p community you can post your own programming questions and respond to other programmers’ questions. Registered users also don't have to see the ads that are displayed to guests. Registration is fast, simple and absolutely free so please, join today!
Join today and post to win prizes! Post more to increase your chances of being Wrox’s top poster of the month.
|
 |

April 25th, 2008, 05:28 PM
|
|
Friend of Wrox
|
|
Join Date: Apr 2005
Location: Fort Walton Beach, FL, USA.
Posts: 190
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
WindowsIdentity - Impersonation Context
On page 52 of the book, the authors show the code for a stored procedure. I am using VS 2008 Pro (C#) and SQL Server 2005 Enterprise. I have not been able to get this code to work. Inside the using statement I have replaced ".\\sqlexpress" with the name of my own SQL Server. My statement reads: using (SqlConnection oConn = new SqlConnection(".\\SQLSERVER2005;Integrated Security=true;")). My code compiles and Deploys fine.
BTW, in order to use the WindowsIdentity and WindowsImpersonationContext objects I had to manually add a using statement for the class for namespace: System.Security.Principal.
I won't go into the err messages posted at query execute time until I know at least one person has got this to work.
If you have successfully executed this code in your SSMS, I would appreciate you posting that fact to this thread so that the rest of us don’t spend a lot of time spinning our wheels uselessly. Thanks.
VictorVictor
|
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
|
 |