The following bcp command is throwing me an error.My Sql server instance is on AWS RDS.
bcp.exe [dbname].[schema].[Tablename] out C:\BCP_OUT\TableName.dat -T -c -U MyUser -P MyPassword -S MyServer\dbname
Error Details:
Error : SQLState = 08001, NativeError = -1
Error = [Microsoft][SQL Server Native Client 11.0]SQL Server Network Interfaces:
Error Locating Server/Instance Specified [xFFFFFFFF].
SQLState = 08001, NativeError = -1
Error = [Microsoft][SQL Server Native Client 11.0]A network-related or instance-
specific error has occurred while establishing a connection to SQL Server. Serve
r is not found or not accessible. Check if instance name is correct and if SQL S
erver is configured to allow remote connections. For more information see SQL Se
rver Books Online.
SQLState = S1T00, NativeError = 0
Error = [Microsoft][SQL Server Native Client 11.0]Login timeout expired
What am i doing wrong ?
Following both worked, first one without native data types and second one with native data types (this is preferred though, if any one wants to use)
bcp.exe [dbname].[schema].[Tablename] out C:\BCP_OUT\TableName.dat -c -U MyUser -P MyPassword -S MyServer
(or)
bcp.exe [dbname].[schema].[Tablename] out C:\BCP_OUT\TableName.dat -U MyUser -P MyPassword -S MyServer -n