I need to pass a very long string parameter from C# to MSSQL server stored procedure via entity framework. For this, Im thinking to use VARCHAR(MAX) as the input parameter type of the stored procedure. and I found that VARCHAR(MAX) supports up to 2^31-1 characters to be stored from the below links.
But, what worries me is when I pass this long string to stored procedure will there be any data loses during the communication from C# to sql server stored procedure, so that VARCHAR(MAX) input parameter would not receive all the characters that sent from C#?
Any guidance or help will be much appreciated. Thanks.
https://learn.microsoft.com/en-us/sql/sql-server/maximum-capacity-specifications-for-sql-server
Maximum length of string which can be returned from stored proc in SQL Server 2008 to .net apps