问题
I'm using SqlCMD
in SQL Server to query my database from my linux machine using the following bash code:
RESULT=`/opt/mssql-tools/bin/sqlcmd -S thedb.server.database.windows.net -d db_123 -U user_123 -P pass_123 -y 50 -Y 50 -I -Q "$SQL_QUERY" -s"|"`
This returns the each column up to 50 characters per column. However, some of my columns go up to 1000 chars in length, and when I include the "-y" and the "-Y" setting, it works up until about 80, then no result.
I've reviewed Microsoft's docs here but that didn't get help. Thank you
来源:https://stackoverflow.com/questions/57015860/sql-servers-sqlcmd-is-truncating-my-columns-returned-and-increasing-the-size-c