Microsoft KB Archive/817845

= FIX: &quot;Login Failed for User 'SYSTEM'&quot; Error When You Use OPENROWSET Function Without UserName =

Article ID: 817845

Article Last Modified on 4/6/2004

-

APPLIES TO


 * Microsoft Data Access Components 2.7
 * Microsoft SQL Server 2000 Service Pack 3

-



SYMPTOMS
When you run a query with the OPENROWSET function, and you do not specify the username and password in the function, you receive the following error message:

Login failed for user 'SYSTEM'



CAUSE
An authenticated standard SQL user who executes ad hoc queries in SQL server, and does not specify a username and a password (or an application that runs over Microsoft SQL OLE DB Provider, and does not specify a username and a password), can cause a connection to occur that has SQL Server Service account as the username, and has a blank password. Therefore, when the SQL Server Service is running under the SYSTEM account, you receive the error message that is listed in the &quot;Symptoms&quot; section that specifies &quot;SYSTEM&quot; as the user.



STATUS
Microsoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article. This bug was corrected in MDAC 2.7 Service Pack 1 Refresh.



Steps to Reproduce the Behavior
  In SQL Query Analyzer, run the following statement: select * from openrowset('sqloledb','';;,'select * from pubs.dbo.authors')  You receive the error message that is described in the &quot;Symptoms&quot; section of this article.



RESOLUTION
For additional information, click the following article number to view the article in the Microsoft Knowledge Base:

269587 INF: Windows Authentication is the Default Security Mode After a SQL Server 2000 Typical Installation

Keywords: kbbug kbuser kbserver kbservice kbquery KB817845

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.