ไม่ว่าฉันจะทำอะไรฉันก็ไม่สามารถทำให้ SQLCMD ทำงานได้ ฉันพยายามเรียกใช้สคริปต์ที่มีขนาด 200mb + และไม่สามารถเรียกใช้จากแอปพลิเคชันเซิร์ฟเวอร์ sql ได้ดังนั้นฉันต้องดำเนินการผ่าน SQLCMD อย่างไรก็ตามทุกครั้งที่ฉันพยายามลงชื่อเข้าใช้หรือเรียกใช้สคริปต์สคริปต์จะปิดทันที
ฉันได้ติดตามยูทิลิตี้ sqlcmd โดย msdn
ฉันพยายามที่จะเปิดมันผ่านคำสั่งที่เชื่อถือได้ SQLCMD -EI รับ:
Sqlcmd: Error: Microsoft SQL Server Native Client 11.0 : Named Pipes Provider: Could not open a connection to SQL Server [2]. .
Sqlcmd: Error: Microsoft SQL Server Native Client 11.0 : Login timeout expired.
Sqlcmd: Error: Microsoft SQL Server Native Client 11.0 : A network-related or instance-specific error has occurred while establishing a connection to SQL Server. Server is not found or not accessible. Check if instance name is correct and if SQL Server is configured to allow remote connections. For more information see SQL Server Books Online..
ฉันได้ลองผ่านทางเซิร์ฟเวอร์ชื่อผู้ใช้และรหัสผ่านที่ชัดเจน:
C:\Users\MyUserName\Documents>SQLCMD -S DESKTOP-1N3OD6V\SQLEXPRESS -U DESKTOP-1N3OD6V\MyUserName-P MyPassword
Sqlcmd: Error: Microsoft SQL Server Native Client 11.0 : Login failed for user 'DESKTOP-1N3OD6V\MyUserName'..