Uhg! For the life of me I can't figure this out!!!
I have a command that bcp's to a remote server (Windows). Works fine. I want to do the exact same thing to a remote server running Linux but I have been very unsuccessful. This is what I have:
The error I'm getting is:
I was thinking, maybe this is outside the scope of bcp? So I was going to tackle it a different way. I used bcp to create a file on my windows server and was going to move it from there to my linux box using pscp:
The error I'm getting using pscp is:
Frustrating!!!
There must be a way to do this!!!
Ideas anybody?!?!?!
-MK
I have a command that bcp's to a remote server (Windows). Works fine. I want to do the exact same thing to a remote server running Linux but I have been very unsuccessful. This is what I have:
Code:
EXEC master..xp_cmdshell 'bcp "SELECT * FROM ##Table" queryout, /home/users/dir1/Download/test.out -S[IP] -U[username] -P[passwd]'
The error I'm getting is:
Code:
SQLState = 08001, NativeError = 17
Error = [Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does not exist or access denied.
SQLState = 01000, NativeError = 2
Warning = [Microsoft][ODBC SQL Server Driver][DBNETLIB]ConnectionOpen (Connect()).
I was thinking, maybe this is outside the scope of bcp? So I was going to tackle it a different way. I used bcp to create a file on my windows server and was going to move it from there to my linux box using pscp:
Code:
EXEC master..xp_cmdshell 'pscp \\WindowsServer\dir1\File [username]@[IP]:/home/dir1/test.out -pw [passwd]'
The error I'm getting using pscp is:
Code:
Fatal: More than one remote source not supported
Frustrating!!!
There must be a way to do this!!!
Ideas anybody?!?!?!
-MK