title: how to connect to SQL Server 2005 from Visual C++
body: <p>Can anybody help to understand how to connect from Visual C++ to SQL Server 2005?</p>
  
  <p>i am developing an ISAPI dll using Visual C++ and i need to query the database to fetch a few details.  I tried to connect to the DB using <code>CDatabase</code>.  When I invoked the dll from a local system, it worked without any issues.  But when i access the dll from a remote system, it's throwing <code>Login failed for user NT AUTHORITY/ANONYMOUS LOGON</code>.</p>
  
  <p>What should I do?</p>