August 26, 2010 at 2:13 am
hi all,
im getting SQLState = 28000, NativeError = 18456 error wen i execute the query mentioned below.
exec master.dbo.xp_cmdshell 'bcp "SELECT * FROM customer for XML auto, ELEMENTS XSINIL" queryout e:\sample.txt -c -T -U"sa" -P"e2s"'
exec master.dbo.xp_cmdshell 'bcp "SELECT * FROM customer for XML auto, ELEMENTS XSINIL" queryout e:\sample.txt -c -T'
im getting this problem even after changing the configuration
config settings
USE master
GO
EXEC sp_configure 'show advanced options', 1
GO
RECONFIGURE WITH OVERRIDE
GO
EXEC sp_configure 'xp_cmdshell', 1
GO
RECONFIGURE WITH OVERRIDE
GO
EXEC sp_configure 'show advanced options', 0
GO
🙁
pls help me
thanks in advance..
March 2, 2011 at 6:34 am
Hi i think u missed the dbname and owner name please try the following query.
exec master.dbo.xp_cmdshell 'bcp "SELECT * FROM [dbname].dbo.customer for XML auto, ELEMENTS XSINIL" queryout e:\sample.txt -c -T -U"sa" -P"e2s"'
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply