xp_logininfo Issue

  • I am having an issue using 'sp_send_dbmail'.

    It was working OK, for several weeks, until last Friday. Now it comes back with;

    Executed

    as user: DDDD\xxxxxx. Query execution failed: Msg 15404, Level 16, State 19, Server BS170404, Line 1 Could not obtain information about Windows NT group/user 'DDDD\xxxxxx', error code 0x5. [SQLSTATE 42000] (Error 14661). The step failed.

    It seems to be the query in the sp_send_dbmail that is failing. I run without the query and the mail is sent OK. I get the same error if I run;

    xp_logininfo 'DDDD\xxxxxx','all'

    This is Standard Edition running on Windows XP, sp2.

    DDDD\xxxxxx is the account I am logged on with, the account that is running SQL , and the owner of the job.

    I looked at the KB articles on troubleshooting xp_logininfo but it was no help.

    Any ideas?

  • This was removed by the editor as SPAM

  • Glynne,

    Is DDDD\xxxxxx domain or local Windows account? Is Domain Controller for the domain available? You say it is your login account. Login to Windows or login to SQL Server with Windows authentication?

    Check if your computer is on the network, that you are using Domain Controller when logging to this computer and you are not logging with cached credentials.

    What do you mean, you send without the query? Did you mean without the job, right from the query window? In this case your login credentials are used. Also checked that you did not change the password for this login recently.

    Regards,Yelena Varsha

  • Yelena,

    DDDD\xxxxxx is a domain account. It is the account I use to lov=g on to the workstation. It is alos the account that is running SQL. The computer is on the network.

    The sp_send_dbmail worked if I did not have it run a query. From the job or from a query window. I ran profiler and it was choking on the EXECUTE AS [DDDD\xxxxxx] command.

    xp_logininfo also failed.

    This started working mgically about a week after the problem started! I suspect it was something to do with the account but I can't confirm anything.

    Thanks anyway!

    Glynne

  • Glynne,

    can you execute this query yourself from the query window in Management Studio without sp_send_mail, just the query? Also, can you execute sp_send_dbmail with another query? Is your query going towards another database or another server?

    I am running sp_send_dbmail as this on my CTP 2005 server on Windows XP workstation: I collect information from multiple queries in the temp table and the last step is to run sp_send_dbmail with the query selecting from the temp table:

    EXEC dbo.sp_send_dbmail @recipients='myemail@mycompany.com',

        @subject = 'SQL Server Backup Status',

        @query ='Select * from ##BackupStatusFormatted',

        @profile_name = 'MyProfile',

     @attach_query_result_as_file = 0

    Yelena

     

    Regards,Yelena Varsha

  • Yelena,

    Everything is working fine now. It started working again yesterday morning.

    I was running a command very similar to yours. I could run the sp_send_dbmail without the query and it worked OK. Everything is on the same server.

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply